ifElse

Use the ifElse function to return an object you want based on a condition. It returns the object you specify if the Boolean value is true and returns the object you specify if the Boolean value is false. You must specify the objects to return in the formula. The ifElse operator can return a Text, DateTime, Integer, or Decimal value.

Operator format

ifElse(Boolean condition, Object if true, Object if false)

  • Boolean condition: the Boolean value that determines which object is returned.
  • Object if true: the returned object if the Boolean condition is true.
  • Object if false: the returned object if the Boolean condition is false.

ifElse example

In the following example formula, the Form.TermsAgreement Boolean variable value is False.

ifElse(Form.TermsAgreement, "Thank you!", "You must agree to the terms")

The formula returns the Text object value You must agree to the terms.