Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2003

    Question Unanswered: After Update event doesn't work if value for control is set automatically via Macro

    Hi All.
    I have a form wherein based on changes to certain fields (any/all of them), I want to change values to other fields. What I have done is that I have written a macro that automatically updates a flag field as soon as any of the required field is changed. As soon as the flag field is updated, in the after update event macro for that flag field, which is basically a check box, I have written another macro to update the other fields. The foll. sequence explains breifly what I want to do.

    Control on form Updated --> Update check box via macro --> after check box updated via macro, update required controls via macro.

    Now both the macros run in after update event of the respective controls. The macros basically contain "setValue" commands to update other field values. However, what I am observing is that even though the check box gets updated, the macro in its after update event is not getting fried. In essence, if the value of the check box event is set through a macro, i.e. automatically, the after update event does not work. Whereas if manually the check box value is changed the after update event is fired. What I want to know is that why does this happen? Shouldn't the after update event for the check box, or any other control for that matter, be fired, irrespective of whether the value for that control is updated automatically or manually? Am I missing something important here or is this a potential flaw in MS Access? I would highly appreciate any clarifications for the above.

    Thanks to all in advnace for your time and efforts.


  2. #2
    Join Date
    Apr 2004
    Derbyshire, UK
    Provided Answers: 1
    Just though, dose the macro actual update the Form record (not just the control), if the record is not saved or moved to another record, then the Form_AfterUpdate does not fire!!


  3. #3
    Join Date
    Mar 2003
    The Bottom of The Barrel
    Provided Answers: 1
    Call the event from the macro?
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts