Skip to Content
avatar image
Former Member

How to summarize a column values into a field

Hi forum

¿ Do you now how to summarize a column table values into one field?

I don´t understand in what event i can to put the code.

And if you can put some code.

For example.

                     |       h1      |        h2       |      h3    |

                     |       rA1    |        rA2      |      rA3   |
                     |       rB1    |        rB2      |      rB3   |
                    ------------------------------------------------------
                     |  rA1 + rB1   |  rA2+ B2       | rA3 + rB3|

Thnks

Josué Cruz

Edited by: Josue Cruz on Sep 2, 2008 12:41 AM

Edited by: Josue Cruz on Sep 2, 2008 12:42 AM

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Sep 02, 2008 at 05:19 AM

    Josue,

    If you have a static table where you know the number of rows and have designed it accordingly in the form then below steps should probably help you.

    1. Drag Table control from standard library and select 3 columns and 3 body rows. Select the lnclude Header and Footer Row options and click OK.

    2. Select the first cell (Cell1 of Row1) and change its Type to Numeric Field from Object palette. Do this for other cells as well.

    3.For cells in footer row, select the calculate event, keep script as Formcalc and enter following code appropriately for the 3 cells.

    // Code in cell1 calculate event of footer row.
    Sum(Table1.Row1.Cell1, Table1.Row2.Cell1, Table1.Row3.Cell1)
    
    // Code in cell2 calculate event of footer row.
    Sum(Table1.Row1.Cell2, Table1.Row2.Cell2, Table1.Row3.Cell2)
    
    // Code in cell3 calculate event of footer row.
    Sum(Table1.Row1.Cell3, Table1.Row2.Cell3, Table1.Row3.Cell3)

    Chintan

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Chintan Virani

      Hi again Chintan

      My first question was answer by you, but for learn a little bit aboute Adobe Form, i wish that if you can explain me how can be a "for" into a table? how can i get the length of rows of a table ?

      Thnks Chintan

      Edited by: Josue Cruz on Sep 3, 2008 3:09 PM