mIRC Home    About    Download    Register    News    Help

Print Thread
$iif bug maybe? #265224 19/03/19 08:25 PM
Joined: May 2016
Posts: 11
W
Wikked Offline OP
Pikka bird
OP Offline
Pikka bird
W
Joined: May 2016
Posts: 11
//echo -a $iif(United States of America,United States of America,USA)

returns

* /if: 'States' unknown operator
* /if: 'States' unknown operator
* /if: 'States' unknown operator
* /if: 'States' unknown operator
* /if: 'States' unknown operator

Re: $iif bug maybe? [Re: Wikked] #265225 19/03/19 09:21 PM
Joined: Jan 2004
Posts: 1,173
maroon Offline
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 1,173
nope, not a bug. you're putting multiple things into the conditional parameter, so it's trying to evaluate the conditional. If you don't want to evaluate multiple terms, then just put 1 term there:

Code:
//echo -a $iif( $+(United States of America) ,$v1,$v2)
//echo -a $iif($left(United States of America,999),$v1,$v2)

Re: $iif bug maybe? [Re: maroon] #265228 20/03/19 04:44 AM
Joined: May 2016
Posts: 11
W
Wikked Offline OP
Pikka bird
OP Offline
Pikka bird
W
Joined: May 2016
Posts: 11
ahh, duh. ty