Here is one and only conditional statement:
If <expression 1> Then ... ElseIf <expression 2> Then ... Else ... EndIf
In conditions, you can use any valid expression, the result of which is equal to “true” or “false”. For true, a string equal to «1» is taken, for a false - «0» or an empty string.
Unlike expressions in command parameters, an expression in conditions is written without quotes with % sign in front of them:
If %AUTORUN_TCARCH% = 32 Then ... EndIf If FileExist("%COMMANDER_PATH%\NoClose.exe") Then ... EndIf
Legacy command use
In Autorun before version 2.0.10, only certain special functions could be used in conditions, while the condition was limited to one function. In later versions, this option is left for compatibility.
If [Not] Function1 <parameters> Then ... ElseIf [Not] Function2 <parameters> Then ... Else ... EndIf
It's allowed to use both expressions and function in one condition (but in different branches).
en/documentation/conditions.txt · Последнее изменение: 2020/04/24 16:30 — loopback