Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Total a unbound text box in the GroopFooder

Status
Not open for further replies.

Loui2005

Programmer
Jan 12, 2005
8
US
Hi Dear All,

I have a problem with getting a total on a text box in the groupfooder section. Here the what the query looks like

Field1 Field2 Field3

Rigion1 6000 NoKey
Rigion1 6000 NoKey
Rigion3 2000 NoKey
Rigion4 5000 NoKey
Rigion2 7000 NoKey
Rigion3 2000 NoKey
Rigion2 7000 NoKey
Rigion4 5000 NoKey
Rigion1 3500 Key
Rigion1 3600 Key
Rigion2 1500 Key
Rigion3 1600 Key
Rigion4 4500 Key

Filed1 is my groupfooder and I have my text box for total, now I want to get the total of Field2 with criteria "Key" and be able to add only one value from Field2 of a single Rigion under citeria "NoKey".

Here the code I use to sum Field2 with criteria "KEY"
=Sum(IIf([Field3]="KEY",[Field2]), I got a good result, but when I add the criteria "NoKey", the text box shows up in blank.

Can anyone help me please?

Lot of Thanks in advance.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top