Tag: SetVarListErrorAction
The SetVarListErrorAction function triggers the construction of lists of errors from failed actions.
<SetVarListErrorAction ListName="ERRORS"/>
XML
Tag Attributes
Attributes | Attribute Values | Value Description | Comment |
---|
ListName | N/A | Name of list containing the errors | Mandatory |
Action | N/A | Name of actions by which to filter errors. Empty or not supplied, all actions are scanned and their errors added to the list | Optional |
Detailed Description
To access the individual error content, loop the list and use {%ErrorAction%} after ExecuteListAction.
Tag: SetVarListErrorSystem
The SetVarListErrorSystem function automates the action of constructing lists of errors that occurred during initialization and other non-action related errors.
<SetVarListErrorSystem ListName="ERRORS"/>
XML
Tag Attributes
Attributes | Attributes Values | Value Description | Comment |
---|
ListName | N/A | Name of list containing errors. | Mandatory |
Example Script
<ytriaAutomation Application="sapio365">
<OnError continue="true"/>
<LoadSession name="DoesNotExist@LetsTriggerAnError"/>
<ShowUsers/>
<SetVarListErrorAction ListName="ERRORS"/>
<Loop list="ERRORS" OnError="Next">
<ExecuteListAction/> <!-- SetVar ErrorAction here: var name is not free -->
<Echo value="Sadness: {%ErrorAction%}"/>
</Loop>
</ytriaAutomation>
XML