The scripting language includes the use of "else" statements. Meaning if it meets a requirement then do something and if it does not do something "ELSE".
An example of the syntax that uses the else statement is listed below:
if (Department = "400") { roundtoschedule (14,0,0,0); } else { roundtoschedule (20,0,0,0); }
In this example, if the Department is equal to 400, then it will round to schedule (assuming the appropriate information has been input into Employee Setup), "ELSE" if the department is anything other than 400 then round to a different value.
Scripting (Main Page) > Scripting - Keywords (Main Page) > TimeWorks: Scripting - ELSE Statement
| |