D
dominic_brunelle
Hi guys,
I am doing a Access project to manage the engineering department
jobs. In a form binded to a table, I am trying to show in a text box
the result of an equation based on the sum of the "value" variable. I
want that equation to update "on change" of the "value" text box. How
would the equation be formulated? Here is what I tried:
--- 1st try ---
Private Sub CommValeur_AfterUpdate()
CommDelaisEntree = DSum("[CommValeur]", "T: CommandeIngenierie",
"[CommandeCompletee] = 'No' AND [CommandeAnnulee] = 'No'") * 0.07 / 42
/ 37.5 / 3.25
End Sub
---------------
I get a runtime '2001' error.
CommValeur : Value variable to be summed
CommDelaisEntree : Variable to be calculated from sum of Value variable
T: CommandeIngenierie : Binded table
CommandeCompletee : states if order is completed, I need to sum only
none completed orders
CommandeAnnulee : states if order was cancelled, I need to sum only
live orders
Any clues?
Thanks guys.
Dominic.
I am doing a Access project to manage the engineering department
jobs. In a form binded to a table, I am trying to show in a text box
the result of an equation based on the sum of the "value" variable. I
want that equation to update "on change" of the "value" text box. How
would the equation be formulated? Here is what I tried:
--- 1st try ---
Private Sub CommValeur_AfterUpdate()
CommDelaisEntree = DSum("[CommValeur]", "T: CommandeIngenierie",
"[CommandeCompletee] = 'No' AND [CommandeAnnulee] = 'No'") * 0.07 / 42
/ 37.5 / 3.25
End Sub
---------------
I get a runtime '2001' error.
CommValeur : Value variable to be summed
CommDelaisEntree : Variable to be calculated from sum of Value variable
T: CommandeIngenierie : Binded table
CommandeCompletee : states if order is completed, I need to sum only
none completed orders
CommandeAnnulee : states if order was cancelled, I need to sum only
live orders
Any clues?
Thanks guys.
Dominic.