Copy link to clipboard
Copied
var qty = Number(this.getField("Q9").valueAsString);
var sys = Number(this.getField("System").valueAsString);
var labor1 = 550;
var labor2 = 495;
if (this.getField("System").valueAsString == "EX500" || this.getField("System").valueAsString == "FS200" || this.getField("System").valueAsString == "TOPOLYZER" || this.getField("System").valueAsString == "LenSx");
event.value = qty * labor1;
else
event.value = qty * labor2;
Im trying to do a simple script that will charge labor and travel depending on what system is selected from dropdown menu. 4 of the systems charge 550 and the rest 495. I had created an OR statement to determine if the charge is 550 or 495, but it fails in the else portion, so I guess the OR statement is being ignored. Maybe Im missing a true/false line but Im not versed enough in script to know The script is in SUB9 and SUB10
Copy link to clipboard
Copied
Remove the ; at the end of the if line.
Copy link to clipboard
Copied
Remove the ; at the end of the if line.
Copy link to clipboard
Copied
wow Danke Bernd. I cant believe this (;) caused so much grief 👍
Working now!!