Calculations in a Repeating Section

M

mark.brown84

I am trying to do what should be a simple task in InfoPath 2003... I
want to multiply 2 fields in a repeating section and set a 3rd's field
value with the result. Ex:

-----Repeating Section-----------------

QTY UNITS TOTAL
1 1 1
2 2 4
3 3 9

-----End Repeating Section----------

When I try to do this the calulation always uses the original values
of QTY and UNITS, (1*1), and not the respective row. Any ideas on how
I could get this to work?

Thanks,
Mark
 
K

Kalyan G Reddy MVP (GGK Tech)

Hello

Double click on the Total Field to open the properties
Click fx at the end of the text box under Default value
Now insert this QTY field and then Insert * and then insert the Units field
the formula should look like (QTY)*(UNITS)

I think you are using the values instead of the fields
 
M

mark.brown84

Hello

Double click on the Total Field to open the properties
Click fx at the end of the text box under Default value
Now insert this QTY field and then Insert * and then insert the Units field
the formula should look like (QTY)*(UNITS)

I think you are using the values instead of the fields

--
Kalyan G Reddy - INFOPATH MVP 2007http://www.ggktech.com










- Show quoted text -

Hi,

I had it exactly that way and it does work fine for the original
entry; however, any addition entires inserted uses the original QTY
and UNTIS fields. Ex:

-----Repeating Section-----------------

QTY UNITS TOTAL
1 1 1
2 2 1
3 3 1

-----End Repeating Section----------
 
K

Kalyan G Reddy MVP (GGK Tech)

Hello

Delete this repeating section and add the fields and the section again and
put the formula on it. This should solve it

Sometimes Infopath has no reasons why it behaves that way.
 
M

mark.brown84

Hello

Delete this repeating section and add the fields and the section again and
put the formula on it. This should solve it

Sometimes Infopath has no reasons why it behaves that way.

--
Kalyan G Reddy - INFOPATH MVP 2007http://www.ggktech.com








- Show quoted text -

Hi,

The problem seems to be that I was using a repeating section and not a
repeating table. I made the change and everything works as expected
now. Thanks for the help

Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top