Go4Expert (http://www.go4expert.com/)
-   MS Access (http://www.go4expert.com/forums/ms-access-forum/)
-   -   After Update statement (http://www.go4expert.com/forums/after-update-statement-t10144/)

edreamers 20Apr2008 14:50

After Update statement
i have a problem. I want to achieve this


i used AfterUpdate() function on form to do the calculation and to save the results in the table.

Private Sub grossSalary_AfterUpdate()
Me.total2 = Me.grossSalary + Me.perquistes + Me.profits
End Sub

Private Sub perquistes_AfterUpdate()
Call grossSalary_AfterUpdate
End Sub

everything is working fine till there. Now in the next fields i have to do calculation on these calculated results and save the results in table.

I want to achieve this:

I tried to use the AfterUpdate function again, but this time its not working.
Private Sub total2_AfterUpdate()
Me.gross_taxableSalary = Me.total2 - Me.total3
End Sub

Private Sub total3_AfterUpdate()
call total2_AfterUpdate()
End Sub

Please help me. its very urgent.

All times are GMT +5.5. The time now is 14:01.