Method Community

 

TIP: Shared Results As Variables When Calling Other Action Sets

Last post 02-25-2013 5:17 PM by Blake C. 0 replies.
Page 1 of 1 (1 items)
Sort Posts: Previous Next
  • 02-25-2013 5:17 PM

    TIP: Shared Results As Variables When Calling Other Action Sets

    Just a quick tip I discovered this week while implementing custom payroll calculation logic. Hopefully others will find this useful in their customization efforts within Method.

    I have a top level button action that includes several different calls to other buttons using the action 'Call Another Action Set'. Once I get the basic functionality working in one button's actions and see the need to use the same logic in another button's actions, I refactor the logic into it's own button. Then, from the calling routine, I create one or more Shared Results to be used as variables. The new button acts as a "sub routine" of sorts and "returns" one or more Shared Results that the calling routine will then use in it's own action sequence once control returns back to it. In the step immediately after the Call Another Action Set, I do a Get Value From Shared Result and use that information to continue on.

    Hopefully that makes sense. Doing something like this really helped me reduce duplication as well as separate and simplify logic. Any changes I need to make or if I need to add new functionality, the work will be more isolated rather than jammed into a huge button with tons of potentially confusing conditional statements.


    Hope this helps

    Blake C
Page 1 of 1 (1 items)