Skip to main content
Participating Frequently
June 8, 2017
Question

Calculation Script problem

  • June 8, 2017
  • 1 reply
  • 259 views

I am trying to write a calculation script where a certain field is 0 the event value produces the sum of 3 fields and when a different field is 0 the event value produces to the sum of 3 other fields.  The script I have written is below.  I keep getting a java script editor message "illegal character 2:  at line 3.  Can you provide some input as to what I am doing incorrectly to obtain my value?

if (this.getField("No of Lots").valueAsString=="")
{
event.value = ( this.getField (“Site Plan Rev Fee”).value + this.getField (“S&E Rev Fee”).value + this.getField (“Future Disturbed Fee”).value + this.getField (“Storm Rev Fee”).value;
}
else if (this.getField("No of Sheets").valueAsString=="")
{
event.value = (this.getField (“Subdiv Plan Rev Fee”).value + this.getField (“S&E Rev Fee”).value + this.getField (“Future Disturbed Fee”).value + this.getField (“Storm Rev Fee”).value;
}

This topic has been closed for replies.

1 reply

Bernd Alheit
Community Expert
Community Expert
June 8, 2017

Why do you use = ( in your code?