[AccessD] Forms BeforeUpdate - Solved

Gustav Brock Gustav at cactus.dk
Sun Jun 22 10:06:01 CDT 2008


Hi Tony

But then setting 

  Cancel = True

should work just as well. Looks much more clean to me.

/gustav

>>> iggy at nanaimo.ark.com 22-06-2008 16:48 >>>
Hey All
Thanks Gustav.

What I found.
BeforeUpdate on a control fires before the code in a button on the form 
when it is clicked.
BeforeUpDate on a form fires after the code in a button on the form when 
it is clicked.

What I did (still needs to be fully tested).
Added my main form as a subform to a blank main form, and moved my 
buttons from the (now) subform to the main form. At the moment  (as 
mentioned a few scenarios to test), the BeforeUpate in the subform fires 
before the code in the button on the main form, so the docmd.cancelevent 
works.






More information about the AccessD mailing list