Highlighted

New to Livecycle: Need to create simple sum script

Avatar

Guest

08-10-2008

I have a form which has 4 fields ("rent", "deposit", "tax", "cleaning")that need to be calculated into a total and then populated into a "Total" field. I had originally created the form in Acrobat and had no problem with the total calculation, but when I moved it over to Livecycle it will no longer work.

Can someone tell me the correct format for creating a javascript or formcalc to complete this function?



Currently the script line is showing as



/*AFSimple_Calculate("SUM", new Array("rent", "deposit", "tax", "cleaning"));*/

Replies

Highlighted

pguerett

09-10-2008

If you use Javascript then the command would look like this:



Total.rawValue = rent.rawValue + deposit.rawValue + tax.rawValue + cleaning.rawValue;