By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,822 Members | 1,055 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,822 IT Pros & Developers. It's quick & easy.

Form Events not working. Urgent

Expert 100+
P: 344
Using Access 2003

Last night I created a new form, nothing special or funny about it. It has 3 toggle buttons on it, and I put an after_update event on them but it failed to work.

I now find that no event will work on any control in that form. They all give the same message

"The expression After_Update you entered as the Event Property setting produced the following error: Object or Class does not support the set of events"

The code in the form is like really basic and just there to test the events.

Anybody any idea what is going on as this has me stumped
Expand|Select|Wrap|Line Numbers
  1. Option Compare Database
  2. Option Explicit
  3. Private Sub DoubleCorrect_AfterUpdate()
  4. If DoubleCorrect Then
  5.     MainCorrect = False
  6.     NeitherCorrect = False
  7. End If
  8. End Sub
  9. Private Sub MainCorrect_AfterUpdate()
  10. MsgBox "Hello"
  11. End Sub
  12. Private Sub MainTableValue_AfterUpdate()
  13. MsgBox "Hello"
  14. End Sub
  15.  
  16. Private Sub NeitherCorrect_AfterUpdate()
  17. If NeitherCorrect Then
  18.     MainCorrect = False
  19.     DoubleCorrect = False
  20. End If
  21. End Sub
  22.  
  23.  
May 31 '07 #1
Share this Question
Share on Google+
4 Replies

puppydogbuddy
Expert 100+
P: 1,923
Using Access 2003

Last night I created a new form, nothing special or funny about it. It has 3 toggle buttons on it, and I put an after_update event on them but it failed to work.

I now find that no event will work on any control in that form. They all give the same message

"The expression After_Update you entered as the Event Property setting produced the following error: Object or Class does not support the set of events"

The code in the form is like really basic and just there to test the events.

Anybody any idea what is going on as this has me stumped
These are all AfterUpdate events for controls, which are not triggered until something has been keyed in. Programmed (background) updates do not trigger the AfterUpdate event for a control, but they do trigger the after update event for the form.
May 31 '07 #2

Expert 100+
P: 344
These are all AfterUpdate events for controls, which are not triggered until something has been keyed in. Programmed (background) updates do not trigger the AfterUpdate event for a control, but they do trigger the after update event for the form.
Hi Puppydogbuddy,

I am keying something in. What I wanted to do was set the other two fields false after the user clicks one true. ATM, I can't get any event to trigger on any control in this form, I keep getting the error message from Access.

All the events on all the other forms work fine, its just this latest form giving this error.
May 31 '07 #3

puppydogbuddy
Expert 100+
P: 1,923
Hi Puppydogbuddy,

I am keying something in. What I wanted to do was set the other two fields false after the user clicks one true. ATM, I can't get any event to trigger on any control in this form, I keep getting the error message from Access.

All the events on all the other forms work fine, its just this latest form giving this error.
Then, I would venture to say you have a corrupted form, unless the error message indicates otherwise. Did you check to see that the event property for each of the controls shows that the AfterUpdate Event has been set?
May 31 '07 #4

Expert 100+
P: 344
Then, I would venture to say you have a corrupted form, unless the error message indicates otherwise. Did you check to see that the event property for each of the controls shows that the AfterUpdate Event has been set?
Looks like corruption. Tried compact and repair, then decompile, still no joy. Then found this on a google search and it fixed the problem. Seems its a known access bug.

Application.SaveAsText acForm, "fsubDoubleEntryCorrectionDetail", "C:\fsubDoubleEntryCorrectionDetail.txt"

Then delete form and do

Application.LoadFromText acForm, "fsubDoubleEntryCorrectionDetail", "c:\fsubDoubleEntryCorrectionDetail.txt"
May 31 '07 #5

Post your reply

Sign in to post your reply or Sign up for a free account.