Navigation:  thinBasic Modules > Core > Numeric handling >

IIF

Previous pageReturn to chapter overviewNext page

 

Description

 

Return TruePartNumericExpression of FalsePartNumericExpression depending on Num_Expression avaluates to True or False.

 

Syntax

 

n  = IIF(Num_Expression, TruePartNumericExpression, FalseNumericExpression)

 

Returns

 

Number

 

Parameters

 

Name

Type

Optional

Meaning

Num_Expression

Numeric

No

Any numerical or logical expression

TruePartNumericExpression

Numeric

No

If Num_Expression will evaluate to %TRUE, TruePartNumericExpression will be evaluated and its value returned

FalseNumericExpression

Numeric

No

If Num_Expression will evaluate to %FALSE, FalsePartNumericExpression will be evaluated and its value returned

 

Remarks

 

Restrictions

 

See also

 

Numeric Handling, IIF$,

 

Examples