Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

"Overall Total" for each person entered in a Table

Avatar

Level 2

How can I get a table that expands using buttons to "total" the number of names when entered in the form?  Right now I have the table automatically number when you click the "Add Row" button, but unfortunately it is adding each number, for instance 1,2,3=6.  Please help!

1 Accepted Solution

Avatar

Correct answer by
Level 7

What you have stated seems correct for when using Formcalc, assuming the object names are correct. Make sure you put it in the Calculation field and it will then update as you go along.

View solution in original post

5 Replies

Avatar

Level 7

Hi,

From your description it sounds like you have one name per row and want to count the row instances. You can do that with the Instance Manager.

If you want to send the amount of rows to a NumericField for example. Add this to the Add Row button click event javascript:

NumericField1.rawValue = Table1.Row1.instanceManager.count;

Here is my test example:

The table row repeats, the button adds the row and count to the NumericField

1408753_pastedImage_0.png

Avatar

Level 2

I appreciate the prompt response, but that is not quite the answer that I need.  Is there a way for me to send you a sample of what I am working.  I also, have some calculations that I have added to the form.

Avatar

Level 2

I am really having trouble with the division calculation.  Can someone please help me with that?

Calculations are:

Quantity * Unit Cost

Per Day Total:

Total number of employees / Total Cost

Per Employee:

Per Day / Total # of Days

Avatar

Correct answer by
Level 7

What you have stated seems correct for when using Formcalc, assuming the object names are correct. Make sure you put it in the Calculation field and it will then update as you go along.