{"id":36,"date":"2015-11-18T16:48:43","date_gmt":"2015-11-18T16:48:43","guid":{"rendered":"http:\/\/o-calcpro.com\/wiki\/?p=36"},"modified":"2015-11-18T17:24:35","modified_gmt":"2015-11-18T17:24:35","slug":"configuring-development-environment-for-o-calc-pro-plugins-and-reports","status":"publish","type":"post","link":"http:\/\/o-calcpro.com\/wiki\/2015\/11\/18\/configuring-development-environment-for-o-calc-pro-plugins-and-reports\/","title":{"rendered":"Development Environment for O-Calc Pro Plugins"},"content":{"rendered":"<h2>Introduction<\/h2>\n<p>This document describes the development process to create a customized O-Calc Pro Plugins and Reports. O-Calc Pro Plugins can be created to perform a wide verity of functions within the O-Calc Pro interface from importing data from some type of field data collection device to exporting the data to different formats or into specialized databases. Plugins can also be developed that manipulate the data right within the O-Calc Pro interface.<\/p>\n<h2>Before You Get Started<\/h2>\n<p>Before you can start to develop an O-Calc Pro Plugin, a few prerequisites are necessary.<\/p>\n<ol>\n<li>You must have O-Calc Pro Version 5.01 or later installed on the development machine at the following location: C:\\Program Files (x86)\\Osmose\\O-Calc Pro\\Bin<\/li>\n<li>You must have Microsoft Visual Studio install on the development machine, this can be Visual Studio Express<\/li>\n<li>\n<div>Optionally you can install the O-Calc Pro Plugin and Report visual studio template to the following location:<\/div>\n<p>C:\\Users\\&lt;username&gt;\\Documents\\Visual Studio 2012\\Templates\\ProjectTemplates<\/p>\n<p>A zip file of the O-Calc Pro Visual Studio Templates can be downloaded from the O-Calc Pro User&#8217;s Website (<a href=\"http:\/\/www.osmoseutilities.com\/o-calcpro\">http:\/\/www.osmoseutilities.com\/o-calcpro<\/a>). The &#8216;O-Calc Pro Visual Studio Templates.zip&#8217; file contains two additional zip files in an &#8216;O-Calc Pro&#8217; subfolder that would be exacted and placed right in the ProjectTemplates folder list above without further unzipping of the files.<\/p>\n<p><img decoding=\"async\" src=\"http:\/\/o-calcpro.com\/wiki\/wp-content\/uploads\/2015\/11\/111815_1548_Configuring1.png\" alt=\"\" \/><strong><em><br \/>\n<\/em><\/strong><\/p>\n<p><em><strong>Note<\/strong>: You must use Visual Studio 2012 or Visual Studio Express 2012 for these templates to work. This document uses examples from Visual Studio Express 2012 for Windows Desktop which can be download at <a href=\"http:\/\/www.microsoft.com\/en-us\/download\/details.aspx?id=34673\">http:\/\/www.microsoft.com\/en-us\/download\/details.aspx?id=34673<\/a><br \/>\n<\/em><\/li>\n<\/ol>\n<h2>Templates<\/h2>\n<p>There are two Microsoft Visual Studio templates that can help jumpstart your O-Calc Pro custom development. Within in Visual Studio Express 2012, a new development project can be started by selecting File -&gt; New Project. The O-Calc Pro templates are Visual C# Templates with the names:<\/p>\n<p style=\"margin-left: 36pt;\"><strong><em>O-Calc Pro Plugin<br \/>\n<\/em><\/strong><\/p>\n<p style=\"margin-left: 36pt;\"><strong><em>O-Calc Pro Report<br \/>\n<\/em><\/strong><\/p>\n<p>In the screenshot below, the O-Calc Pro Plugin template has been selected and a unique project name of &#8216;MyOCalcProPlugin&#8217; has been entered.<\/p>\n<p><img decoding=\"async\" src=\"http:\/\/o-calcpro.com\/wiki\/wp-content\/uploads\/2015\/11\/111815_1548_Configuring2.png\" alt=\"\" \/><\/p>\n<p>The <strong><em>O-Calc Pro Plugin<\/em><\/strong> visual studio project includes three components that developer can make use of:<\/p>\n<ul>\n<li><strong>AssemblyInfo.cs<\/strong> \u2013 can be used to change various general properties of the plugin<\/li>\n<li><strong>References<\/strong> \u2013 A number of O-Calc Pro library references are include that the developer can use. These references enable the normal Visual C# IntelliSence drop-down menus for the developer.<\/li>\n<li><strong>Plugin.cs<\/strong> \u2013 This is the main source file of the <strong><em>O-Calc Pro Plugin<\/em><\/strong>. Within this file, the developer can determine the type of plugin (Menu Item, Docked Tab, or both) and write the code to perform the plugin tool&#8217;s operation.<\/li>\n<\/ul>\n<p>The <strong><em>O-Calc Pro Report<\/em><\/strong> visual studio project includes four components that the developer can make use of:<\/p>\n<ul>\n<li><strong>AssemblyInfo.cs<\/strong> \u2013 can be used to change various general properties of the report<\/li>\n<li><strong>References<\/strong> \u2013 A number of O-Calc Pro library references are include that the developer can use. These references enable the normal Visual C# IntelliSence drop-down menus for the developer.<\/li>\n<li><strong>Helpers.cs<\/strong> \u2013 This a helper source file of the <strong><em>O-Calc Pro Report<\/em><\/strong> template. This source file contains various helper methods that aid in formatting the report. Items such as creating and formatting tables, color coding text based on loading values, and manipulating images and graphics.<\/li>\n<li>\n<div><strong>Report.cs<\/strong> \u2013 This is the main source file of the <strong><em>O-Calc Pro Report<\/em><\/strong> template. This source file enables the developer to define the various aspects of the report format including colors, fonts, and data to be displayed. There are also methods to implement more than one report subtype and determining the structure type that is applicable for this report.<\/div>\n<\/li>\n<\/ul>\n<a class=\"synved-social-button synved-social-button-share synved-social-size-48 synved-social-resolution-single synved-social-provider-facebook nolightbox\" data-provider=\"facebook\" target=\"_blank\" rel=\"nofollow\" title=\"Share on Facebook\" href=\"https:\/\/www.facebook.com\/sharer.php?u=http%3A%2F%2Fo-calcpro.com%2Fwiki%2Fwp-json%2Fwp%2Fv2%2Fposts%2F36&#038;t=Development%20Environment%20for%20O-Calc%20Pro%20Plugins&#038;s=100&#038;p&#091;url&#093;=http%3A%2F%2Fo-calcpro.com%2Fwiki%2Fwp-json%2Fwp%2Fv2%2Fposts%2F36&#038;p&#091;images&#093;&#091;0&#093;=http%3A%2F%2Fo-calcpro.com%2Fwiki%2Fwp-content%2Fuploads%2F2015%2F11%2F111815_1548_Configuring1.png&#038;p&#091;title&#093;=Development%20Environment%20for%20O-Calc%20Pro%20Plugins\" style=\"font-size: 0px;width:48px;height:48px;margin:0;margin-bottom:5px;margin-right:5px\"><img decoding=\"async\" alt=\"Facebook\" title=\"Share on Facebook\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"48\" height=\"48\" style=\"display: inline;width:48px;height:48px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"http:\/\/o-calcpro.com\/wiki\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/96x96\/facebook.png\" \/><\/a><a class=\"synved-social-button synved-social-button-share synved-social-size-48 synved-social-resolution-single synved-social-provider-twitter nolightbox\" data-provider=\"twitter\" target=\"_blank\" rel=\"nofollow\" title=\"Share on Twitter\" href=\"https:\/\/twitter.com\/intent\/tweet?url=http%3A%2F%2Fo-calcpro.com%2Fwiki%2Fwp-json%2Fwp%2Fv2%2Fposts%2F36&#038;text=O-Calc%20Pro%20Information\" style=\"font-size: 0px;width:48px;height:48px;margin:0;margin-bottom:5px;margin-right:5px\"><img decoding=\"async\" alt=\"twitter\" title=\"Share on Twitter\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"48\" height=\"48\" style=\"display: inline;width:48px;height:48px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"http:\/\/o-calcpro.com\/wiki\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/96x96\/twitter.png\" \/><\/a><a class=\"synved-social-button synved-social-button-share synved-social-size-48 synved-social-resolution-single synved-social-provider-linkedin nolightbox\" data-provider=\"linkedin\" target=\"_blank\" rel=\"nofollow\" title=\"Share on Linkedin\" href=\"https:\/\/www.linkedin.com\/shareArticle?mini=true&#038;url=http%3A%2F%2Fo-calcpro.com%2Fwiki%2Fwp-json%2Fwp%2Fv2%2Fposts%2F36&#038;title=Development%20Environment%20for%20O-Calc%20Pro%20Plugins\" style=\"font-size: 0px;width:48px;height:48px;margin:0;margin-bottom:5px;margin-right:5px\"><img decoding=\"async\" alt=\"linkedin\" title=\"Share on Linkedin\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"48\" height=\"48\" style=\"display: inline;width:48px;height:48px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"http:\/\/o-calcpro.com\/wiki\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/96x96\/linkedin.png\" \/><\/a><a class=\"synved-social-button synved-social-button-share synved-social-size-48 synved-social-resolution-single synved-social-provider-mail nolightbox\" data-provider=\"mail\" rel=\"nofollow\" title=\"Share by email\" href=\"mailto:?subject=Development%20Environment%20for%20O-Calc%20Pro%20Plugins&#038;body=O-Calc%20Pro%20Information:%20http%3A%2F%2Fo-calcpro.com%2Fwiki%2Fwp-json%2Fwp%2Fv2%2Fposts%2F36\" style=\"font-size: 0px;width:48px;height:48px;margin:0;margin-bottom:5px\"><img decoding=\"async\" alt=\"mail\" title=\"Share by email\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"48\" height=\"48\" style=\"display: inline;width:48px;height:48px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"http:\/\/o-calcpro.com\/wiki\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/96x96\/mail.png\" \/><\/a>","protected":false},"excerpt":{"rendered":"<p>Introduction This document describes the development process to create a customized O-Calc Pro Plugins and Reports. O-Calc Pro Plugins can be created to perform a wide verity of functions within the O-Calc Pro interface from importing data from some type of field data collection device to exporting the data to different formats or into specialized ..<\/p>\n<div class=\"clear-fix\"><\/div>\n<p><a href=\"http:\/\/o-calcpro.com\/wiki\/2015\/11\/18\/configuring-development-environment-for-o-calc-pro-plugins-and-reports\/\" title=\"read more...\">Read more<\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[],"class_list":["post-36","post","type-post","status-publish","format-standard","hentry","category-plugin-development"],"_links":{"self":[{"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/posts\/36","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/comments?post=36"}],"version-history":[{"count":3,"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/posts\/36\/revisions"}],"predecessor-version":[{"id":39,"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/posts\/36\/revisions\/39"}],"wp:attachment":[{"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/media?parent=36"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/categories?post=36"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/o-calcpro.com\/wiki\/wp-json\/wp\/v2\/tags?post=36"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}