So really all IIF really is is this:

code:
Break On

$x = IIF2(1=1,1+1,2+2)

Exit 1

Function IIF2($x,$y,$z)

If $x
$IIF2=$y
Else
$IIF2=$z
EndIf

EndFunction

And to my mind, IIF is only really usefull for quick one-shot conditional assignments - using throw-away expressions. Comments ?

[ 09. January 2003, 01:25: Message edited by: Shawn ]