Well I will try to explain it better... The continuous form is based on a query that contains the following Fields: Product, Quantity, Price, Discount, and Subtotal, all these fields are bound to two tables. Discount is on the Orders table together with Price and Quantity. Product is on the product table. The subtotal is a calculated field within the query. The product is on a combobox and the AfterUpdate Event contains the following VBA
Code:
If Me.Parent.CustDiscount = 1 And Me.ProductDiscount = 1 Then
Me.Discount = 5
Else
Me.Discount = 0
End If
End Sub
This code is supposed to find out if the product and customer get the 5 % discount or not. When I order only one product then it works fine, but when there are many products in the continuous form then the last entry changes the value of Discount for all the products. So that if it is a discounted product then all the products get discount, and the reverse. I don't understand why it changes the values of the previous records within the same OrderID. It only happens to the Discount Field and not to the Price or Quantity. Thanks again for your help and ideas.