These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Radio Button to update various table calculations

ccody
Registered: May 26 2007
Posts: 4

I am trying to use LiveCycle 8 and find a way to update the various calculations in each row contained in a very large table. I am using formcalc. The calculations in various cells need to be changed based on a user’s radio button selection.
 
As an example, I have a table with 5 rows and 5 columns. The 5th row contains a grand total of all the values contained in the above columns.
 
The table looks like this:
 
Cell1, Cell2, Cell3, Cell4, Cell5
Cell1, Cell2, Cell3, Cell4, Cell5
Cell1, Cell2, Cell3, Cell4, Cell5
Cell1, Cell2, Cell3, Cell4, Cell5
Total1, Total2, Total3, Total4, Total5
***all are numeric fields
 
The script on the radio button applied on change is as follows:
 
Button 1-
form1.#subform[0].Table1.*.Cell1.calculate = SUM(Cell2 + Cell3)
 
Button 2-
form1.#subform[0].Table1.*.Cell1.calculate = SUM(Cell4 + Cell5)
 
If I apply SUM (Cell4 + Cell5) or SUM (Cell2 + Cell3) manually as calculate scripts the formulas work fine.
 
When I try and update the calculations of all instances of ‘Cell1’ using the radio button I get “Accessor ‘Cell2’ is unknown”.
 
Any help would be appreciated.
 
Thanks
 
Chris

My Product Information:
Acrobat Pro 8, Windows
thomp
Expert
Registered: Feb 15 2006
Posts: 4411
The SOM path used on the Left of the assignment statement references more than one value. This is illegal. You can only assign a value to a single field. The SOM Path must reference a single field.

Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script