Executes a GeneXus object or an external program within a Transaction. This rule can only be included in the Rules section of a Transaction object.
Call('pgm', [ parm1, parm2 ,... ] ) [ If cond ];
Is the GeneXus object or external program that will be called when the condition cond is true. Use apostrophes or quotes to specify the external program's name.
parm1, parm2 ,...
Are optional parameters that can be sent to the called object with a purpose. They must be received in the called object by declaring them with the Parm rule.
Is the condition that will be evaluated in order to call the ‘pgm’ (true) or not (false). If cond is omitted, the rule will always be triggered.
The following transaction rule invokes a report that prints a Purchase Order immediately after executing the commit in the transaction where the rule is defined:
Call(RPtOrder, OrdNbr) on Aftercomplete;
The following transaction rule invokes a report that prints a Purchase Order immediately after executing the commit in the transaction where the rule is defined. The name of the called object is loaded in a variable:
&Pgm = 'RPtOrder';
The following transaction rule invokes an object defined in the KB. The name of the called object is stored in the attribute named: PgmName. All you need to do is to add the prefix ATT: to the name of the attribute that stores the name of the object you want to call:
Call(ATT:PgmName, parm1, parm2, …);
Two parameters are sent to the called object.
: We recommend using the Call method
instead of this rule, excepting the case you need to indicate the name of the called object in a variable and you need also to define the invocation in the rules section of a transaction.
Significant object name length property
Expand dynamic calls property
Prefixes to use when calling and having to indicate explicitly certain definitions