Logi Composer
Documentation
Getting Started
Knowledge Base
Forums
Logi Report
Documentation
Getting Started
Knowledge Base
Forums
Logi Report API Doc
Logi Info
Documentation
Getting Started
Knowledge Base
Forums
Logi Info Sample Center
Logi Info Upgrade Advisor
Other Products
Izenda
Exago
Support
Submit a Ticket Request
View Support Tickets
License Manager
Product Download
Forums
Events
☰
Element Details: Procedure.Switch
Back
Available in: Logi Info
Source code name:
Procedure.Switch
Introduced in: 12.6
The Procedure.Switch element works with child Procedure.SwitchCase elements to define conditional blocks of Procedures to be performed when values match. Use Procedure.Switch elements when there are multiple conditional blocks defined, with just one to be run based on a variable.
Set the Expression attribute to javascript which evaluates to some value. Then a child Procedure.SwitchCase element having a matching CompareValue attribute will have its child Procedure elements run.
<Procedure Expression="'@Request.color~'" ID="switchColor" Type="Switch">
<Procedure CompareValue="green" Type="SwitchCase" ID="caseGreen" IdeDisplayStatus="Collapsed">
<Response Type="Raw" Value="Green" ID="responseGreen" />
</Procedure>
<Procedure CompareValue="red" Type="SwitchCase" ID="caseRed">
<Response Type="Raw" Value="Red" ID="responseRed" />
</Procedure>
<Procedure CompareValue="caseRed" Type="SwitchElse" ID="caseUnknown">
<Response Type="Raw" Value="Unknown Color" ID="responseUnknown" />
</Procedure>
</Procedure>
Element Group:Logic
ATTRIBUTES
Click attribute Name to drill down for more information.
Name
Possible Values
Description
DataType
Text
Number
Specifies the type of data present.
Expression
UserDefined
(Required) For Procedure.If, Procedures under this element will run when the Expression is true. For Procedure.Switch, Procedures under a Procedure.SwitchCase with a matching value are run.
ID
UserDefined
(Required) The ID attribute is a pervasive attribute that uniquely identifies an element within a definition file. The ID needs to be a unique value within the definition.
PARENT ELEMENTS
Click element to drill down for more information.
If Error
Procedure.Else
Procedure.File Exists
Procedure.Folder Exists
Procedure.If
Procedure.Run Datalayer Rows
Procedure.Run DataTable Rows
Procedure.Switch Case
Procedure.Switch Else
Task
CHILD ELEMENTS
Click element to drill down for more information.
If Error
Procedure.Switch Case
Procedure.Switch Else
Back to top
Your session will automatically end soon.
Continue the Session