Branching Instructions

Navigation:  Appendices > Macro Language > Instructions >

Branching Instructions

Previous pageReturn to chapter overviewNext page

Branching instructions allow you to execute different code, depending on some condition.

 

In the Q++ Macro Language, there are 2 types of branches :

 

if-else

The if type of branch allows you to define 2 paths of execution, depending on the value of a boolean expression.

switch

The switch type of branch allows you to define many different paths of execution, depending on the value of a string or integer expression.

 

 

Note that, as the boolean data type only has 2 possible values (true/false), the if branch can be considered to be a special case of the switch statement as defined for booleans.


Topic 122700 updated on 09-Jan-2003.
Topic URL: http://www.qppstudio.net/webhelp/index.html?branchinginstructions.htm