Navigation:  Deposit Screens > Definitions Screen Group > Service Charges Screen > EZ4U Programming > EZ4U Commands >

ELSEIF Command

Navigation:  Deposit Screens > Definitions Screen Group > Service Charges Screen > EZ4U Programming > EZ4U Commands >

ELSEIF Command

Previous pageReturn to chapter overviewNext page  Print this Topic

This Command is one of several commands available to use in EZ4U Programming. The syntax used to enter this command is specified below, followed by a more detailed explanation of the command itself and a few examples.

 

Syntax: ELSEIF {value} {logical operator} {value}

 

An ELSEIF command is used to compare two values using Logical Operators. An ELSEIF command must follow an IF or ORIF command. ELSEIF commands allow you to designate further comparisons between additional values if the preceding IF and/or ORIF statements prove false. If the IF and/or ORIF statements prove true, the system disregards any subsequent ELSEIF statements.

 

The values compared can be Constants, Variables, or Expressions. The outcome of an ELSEIF command is either true or false. If it is true, the system continues to the next Statement and performs it. If it is false, the system looks for a subsequent ELSEIF or ORIF command and continues at that point. If one is not found, no service charge will be processed.

 

An ELSEIF command can be written as ELSE IF. An ELSEIF command with no corresponding value or Expression can be written as ELSE.

 

IF, ORIF, or ELSEIF command with no Expressions are always true.

 

Examples

 

IF AVGBAL >= 1000.00

CHARGE 1.00

ELSEIF AVGBAL < 1000.00

CHARGE 2.00

If the average balance on the customer account is greater than or equal to $1,000.00, the account will be charged a $1.00 service charge. However, if the average balance is less than $1,000.00, the account will be charged a $2.00 service charge.

 

IF #ATM >= 5

IF AVGBAL >= 1000.00

CHARGE 1.00

ELSEIF #ATM >= 5

CHARGE 5.00

If the number of ATM transactions is greater than or equal to 5, and the average balance on the customer account is greater than or equal to $1,000.00, the account will be charged a $1.00 service charge. However, if the second IF statement proves false, but the first is still true, the account will be charged a $5.00 service charge. Notice that the first IF statement is actually repeated in the ELSEIF statement.

 

IF #ATM > 5

AND IF #ATM < 10

THEN CHARGE #ATM * .60

ELSE

CHARGE 5.00

If the number of ATM transactions is greater than 5 and less than 10, charge $0.60 per ATM transaction. If the number of ATM transactions is not greater than 5, charge $5.00.

©2020 GOLDPoint Systems. All rights reserved.