{"id":1303,"date":"2008-02-29T03:45:31","date_gmt":"2008-02-29T09:45:31","guid":{"rendered":"http:\/\/www.mrc-productivity.com\/docs\/?page_id=1303"},"modified":"2024-01-05T11:28:43","modified_gmt":"2024-01-05T17:28:43","slug":"parameter-calculations-formerly-known-as-constant-calcs","status":"publish","type":"ht_kb","link":"https:\/\/www.mrc-productivity.com\/docs\/knowledge-base\/parameter-calculations-formerly-known-as-constant-calcs","title":{"rendered":"Parameter Calculations"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Overview<\/h2>\n\n\n\n<p>Parameter calculations are a great technique when you are trying to pass a value between multiple applications. For example, you would like to pass a value from the prompt page or URL to the output page to determine some conditional calculations. In our case, our calculation would accept a value, then a conditional calculation would determine what to print in our table data based on the parameter calc.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to Work with Parameter Calculations<\/h2>\n\n\n\n<p>The key to parameter calculation fields is that when you create it, you are merely creating a holder that will hold a value for later. In our case, the &#8220;later&#8221; will be when the value is passed via the prompt page.<\/p>\n\n\n\n<p>To create this place holder, go to the Calculations screen. At the calculation definition screen, select &#8220;Parameter&#8221; from the Calc Type dropdown list. Next, enter your description field. For decimal, choose an appropriate value (In our case, our output needs to be alpha). <\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"\/docs\/vue-images\/parametercalcs1.jpg\" alt=\"\"\/><\/figure>\n\n\n\n<p>Next, setup your conditional calculation to best fit your needs. For our example, we will say that if the value passed to CALCULA001 is &#8216;IL&#8217; then our Calculation will read &#8216;ILLINOIS&#8217;, if not it will say &#8216;OTHER STATE&#8217;.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"\/docs\/vue-images\/parametercalcs2.jpg\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"\/docs\/vue-images\/parametercalcs3.jpg\" alt=\"\"\/><\/figure>\n\n\n\n<p>To have end users enter a value at the prompt page, add a Filter and choose CALCULA001 from the Field dropdown list. Once selected, the page will automatically change to have your parameter calc as a Runtime value prompt. Here you may optionally enter a default value as well.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/www.mrc-productivity.com\/docs\/vue-images\/paracalcrls.png\" alt=\"\" title=\"Parameter Calc Record Selection\"\/><\/figure>\n\n\n\n<p>Make any other changes as needed to your application and then click &#8220;Build app&#8221;.<\/p>\n\n\n\n<p>If wanting to enter your value through the URL, when you run your application, simply add <code>CALCULA001=IL&amp;run=2<\/code> to the URL, and press enter. Based on the value you&#8217;ve passed in the URL, you can control your Conditional calculation.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview Parameter calculations are a great technique when you are trying to pass a value between multiple applications. For example, you would like to pass a value from the prompt page or URL to the output page to determine some conditional calculations. In our case, our calculation would accept a&#8230;<\/p>\n","protected":false},"author":1,"comment_status":"closed","ping_status":"closed","template":"","format":"standard","meta":{"footnotes":""},"ht-kb-category":[253],"ht-kb-tag":[],"class_list":["post-1303","ht_kb","type-ht_kb","status-publish","format-standard","hentry","ht_kb_category-calculations"],"_links":{"self":[{"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/ht-kb\/1303","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/ht-kb"}],"about":[{"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/types\/ht_kb"}],"author":[{"embeddable":true,"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/comments?post=1303"}],"version-history":[{"count":11,"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/ht-kb\/1303\/revisions"}],"predecessor-version":[{"id":13968,"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/ht-kb\/1303\/revisions\/13968"}],"wp:attachment":[{"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/media?parent=1303"}],"wp:term":[{"taxonomy":"ht_kb_category","embeddable":true,"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/ht-kb-category?post=1303"},{"taxonomy":"ht_kb_tag","embeddable":true,"href":"https:\/\/www.mrc-productivity.com\/docs\/wp-json\/wp\/v2\/ht-kb-tag?post=1303"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}