**fScan Reference Manual, Chapter 2 (CmdLineOptions): if** ===== If -- Test some condition before executing commands ===== **usage:** -if EXPR { COMMANDS }\\ **or:** -if ! EXPR { COMMANDS } ===== ===== *EXPR -This argument to IF must be an expression that will yield a numerical value. If EXPR > 0, the COMMANDS string inside the curly brackets will be executed next.\\ Otherwise, the COMMANDS string will be ignored. EXPR can be a single number, an arithmetic expression, or a [[jvs:fscan:manual:chapter1:status|status query]]. The EXPR argument must not contain any spaces within it. Examples of valid EXPR arguments are: $xdim - data set image width ?taskname - query whether the TASKNAME variable is set for the current data set $zdim-30 - true if there more than 30 slices (ZDIM) exists(param.tmp) - true if file "param.tmp" exists If '!' appears before the EXPR argument, the IF condition is true if EXPR is 0.\\ Note: the '!' must be separated from IF and EXPR by spaces. **See Also:**\\ [[jvs:fscan|fScan Home]], [[jvs:fscan:manual|fScan Manual]], [[jvs:fscan:manual:chapter2|CmdLineOptions]], [[jvs:fscan:manual:help|Manual Help]]