Sum up unbound fields

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,
I have a basic sales order form that is only going to be used for
printing purposes. However, I made a column of Quantity fields where the
sales people can enter and ammount of product they are selling. These text
box fields are not bound to anything but what I want to do is total it at the
bottom.

I did =([Quant1])+([Quant2]).......etc. however at the bottom all it does is
add the #'s in succession but does not actually ADD them.

Any help on this would be much appreciated.

Thanks,

Paul
--
 
Try using the appropriate conversion factor (CLng, CCur, CInt, etc) to
ensure that they're treated as numbers, not text:

=CCur([Quant1])+CCur([Quant2])....

And, if there's a chance that a field might be blank, you want to include
the Nz function:

=CCur(Nz([Quant1], 0))+CCur(Nz([Quant2], 0))....
 
Assuming that Quant1, Quant2 are the actual textbox names, use what you have
without the parentheses.
 
Thanks Doug, that was the one that did it for me.


--
-------------------------
I only speak in php/mySQL
so excuse my english....
-------------------------
http://www.gzws.com


Douglas J Steele said:
Try using the appropriate conversion factor (CLng, CCur, CInt, etc) to
ensure that they're treated as numbers, not text:

=CCur([Quant1])+CCur([Quant2])....

And, if there's a chance that a field might be blank, you want to include
the Nz function:

=CCur(Nz([Quant1], 0))+CCur(Nz([Quant2], 0))....

--
Doug Steele, Microsoft Access MVP

(no e-mails, please!)


psquillace said:
Hello,
I have a basic sales order form that is only going to be used for
printing purposes. However, I made a column of Quantity fields where the
sales people can enter and ammount of product they are selling. These text
box fields are not bound to anything but what I want to do is total it at the
bottom.

I did =([Quant1])+([Quant2]).......etc. however at the bottom all it does is
add the #'s in succession but does not actually ADD them.

Any help on this would be much appreciated.

Thanks,

Paul
 
Back
Top