automatic calculations with drop down fields

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

Guest

I am creating a order form for our hockey team. In a table I have 4 colums
with drop down fields in four colums, product, quantity and price. The 4th
colum is for the total price for the item. When I use he formula for column
d times column e (quantity x's price) it will not put a value in the fourth
column. Is it because the other columns are drop down field columns? If so,
how can I get this form to calculate the total price for the item? Also, if
you change the quantity how do you get the total column to automatically
calculate the change? Thanks
 
It is poor practice to store a calculated value that can easily be
recalculated from other stored values. Calculate the total price in a
calculated control in the form or report, or in the query. Assuming you do
the former, once any field that is a factor in the calculation is changed,
you want to requery the calculated field. If one of the factors is changed,
its AfterUpdate event will fire, and that is where you can put the code,
something like:

Me.txtTotalAmt.Requery

Larry Linson
Microsoft Access MVP
 
Back
Top