<< Click to Display Table of Contents >> Navigation: 5. Detailed description of the Actions > 5.21. TA - System Tools > 5.21.10. Run Selected Pin |
Icon:
Function: runSelectedPin
Property window:
Short description:
Do a “If…then…else …” inside a graph (branching instruction).
Long Description:
The parameter P1 can have two different values :
•Execute all boxes on all input pins
•Execute the boxes on the input pin number given here below
There are, basically, three different techniques to do a “If…then…else …” inside Anatella.
“If…then…else …” technique (1): based on the “Abort” action
This first technique is very easy to use:
The draw back of this technique is: This technique is not very flexible: it only allows to “skip” the execution of some Actions at the end of an Anatella graph.
“If…then…else …” technique (2): based on the “runSelectedPin” Action
Here is an example:
This technique is very flexible and very useful.
In the example above, the global parameter “selectedPin” can takes two values (0 or 1) and thus the first or the second input-branch of the runSelectedPin Action is executed. Now, nothing is stopping you from using a global parameter “selectedPin” that is in the range from 0 to 10: you’ll just have 10 input-branches to the runSelectedPin action (and Anatella will execute only one of these branches). In this sense, the runSelectedPin action is more like a “CASE…WHEN” branching instruction (where you can have many different outomes).
The only (little) drawback of the runSelectedPin action is that you need to be familiar with the way how “global parameters” works inside Anatella. For more information on “global parameters”, see the section 5.1.5.
“If…then…else …” technique (3): based on the “LoopAdv” Action
Here is an example: