Algosim documentation: if

if

Performs conditional evaluation.

Syntax

Description

if(b, expr1, expr2) evaluates b, and if the result is true, the function evaluates expr1 and returns the result; otherwise, expr2 is evaluated and the result of it is returned. If b evaluates to false and expr2 is not present, the function returns null.

Examples

if(MessageBox("Do you want to exit?", '("&Yes", "&No"), "Yes", "No") = "Yes", exit())