| Command group | Flag affected | Reversible | Execute on client | Platform(s) |
| Constructs | NO | NO | YES | All |
The Case statement is part of a Switch construct that chooses one of an alternative set of options. The options in a Switch construct are defined by the subsequent Case commands. The Case command takes either a constant, field name, single calculation, or a comma-separated series of calculations. You must enclose string literals in quotes. Date values must match the date format in #FDT.
# Show the direction lPosition equals. eg. if lPosition equals 3 show 'South' in the ok message
SwitchlPositionCase1CalculatelDirectionas'North'Case2CalculatelDirectionas'East'Case3CalculatelDirectionas'South'Case4CalculatelDirectionas'West'
End Switch
OK message{Position [lCount] = [lDirection]}
# Multiple conditions can be used in a comma-separated list to one Case statement.# Default is used to specify commands that should run if the value is not one of# those specified in the Case statements
SwitchlDirectionCase'North','South'OK message{The direction is North or South}Case'East','West'OK message{The direction is East or West}DefaultOK message{The direction is Unknown}## ; lDirection is none of the above
End Switch