From WikiChip
Difference between revisions of "mirc/commands/elseif"
m (Bot: Adding a template) |
m (Bot: Fixing links) |
||
Line 1: | Line 1: | ||
− | The '''/elseif command''' is a [[Conditional statements - mIRC|construct in the mIRC scripting language]] that performs commands if all the previous | + | The '''/elseif command''' is a [[Conditional statements - mIRC|construct in the mIRC scripting language]] that performs commands if all the previous {{mIRC|/if}} or {{mIRC|/elseif}} failed and if the condition is true, must be used after an if/elseif statement. |
− | The elseif statement is used in conjunction with the | + | The elseif statement is used in conjunction with the {{mIRC|/if}} statement and the {{mIRC|/else}} statement to jump to certain blocks of code depending on the result of the conditional statement that was executed. |
== Synopsis == | == Synopsis == | ||
Line 35: | Line 35: | ||
* [[$isalias identifier - mIRC|$isalias]] | * [[$isalias identifier - mIRC|$isalias]] | ||
* [[$iif identifier - mIRC|$iif]] | * [[$iif identifier - mIRC|$iif]] | ||
− | * | + | * {{mIRC|/alias}} |
− | * | + | * {{mIRC|/goto}} |
− | * | + | * {{mIRC|/halt}} |
− | * | + | * {{mIRC|/return}} |
− | * | + | * {{mIRC|/while}} |
− | * | + | * {{mIRC|/returnex}} |
− | * | + | * {{mIRC|/elseif}} |
− | * | + | * {{mIRC|/else}} |
{{mIRC command list}} | {{mIRC command list}} | ||
[[Category:MIRC commands]] | [[Category:MIRC commands]] |
Revision as of 18:39, 5 July 2014
The /elseif command is a construct in the mIRC scripting language that performs commands if all the previous /if or /elseif failed and if the condition is true, must be used after an if/elseif statement.
The elseif statement is used in conjunction with the /if statement and the /else statement to jump to certain blocks of code depending on the result of the conditional statement that was executed.
Synopsis
elseif (<condition>) <command> elseif (<condition>) { <commands> }
Switches
None
Parameters
- <condition> - a conditional expression to be executed
Example
alias test { if ($1 == 1) echo -a 1! elseif ($1 isnum 2-7) echo -a 2-7! }
Compatibility
Added: 4.5
Added On: 30/06/96
Note: Individual switches were not taken into consideration.
See also
- List of commands
- List of identifiers
- $halted
- $result
- $alias
- $isalias
- $iif
- /alias
- /goto
- /halt
- /return
- /while
- /returnex
- /elseif
- /else
mIRC commands list