A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Access says I entered an event property for On Current, but I didn't.



 
 
Thread Tools Display Modes
  #1  
Old April 21st, 2008, 07:49 PM posted to microsoft.public.access.forms
Rachel Garrett
external usenet poster
 
Posts: 41
Default Access says I entered an event property for On Current, but I didn't.

I have a form with two subforms that was working fine until a few
hours ago. Now, when I open up the form, I get this error message
every time I open it, try to move to a new record, or do anything else
besides scroll through the subforms:

"The expression On Current you entered as the event property setting
produced the following error: Object or class does not support the set
of events.

* The expression may not result in the name of a macro, the name of a
user-defined function, or [Event Procedure].
* There may have been an error evaluating the function, event, or
macro."

Now, I haven't changed any properties of any controls or labels,
except for changing one box to 16-point font instead of 8-point font.
I haven't changed properties of anything else either, to my knowledge.
Maybe it was a misplaced keystroke.

I would like to know how I get back to the event property setting and
change it to the default value. How can I get there?

Thanks,
Rachel
  #2  
Old April 21st, 2008, 08:18 PM posted to microsoft.public.access.forms
BruceM[_2_]
external usenet poster
 
Posts: 1,763
Default Access says I entered an event property for On Current, but I didn't.

That is not one of the more helpful error messages. Not only does it not
usually have anything to do with the Current event, but it could mean quite
a few other things. It often means you are trying to do something such as
set a combo box row source in code, but something such as a misnamed field
is preventing it from happening. It could be that you are using a reserved
word for a field or control name, or in some other way there is an ambiguous
name that Access is interpreting as something other than you intend. I
think it could also mean there is a references problem. Try compiling your
code. If that doesn't point to the problem you could try a compact and
repair, or create a new blank database (with name auto-correct turned off)
into which you import all of the objects from the current database.
Another thing to try is commenting out all of the code, then opening the
form. If all is well, uncomment the code one function or sub at a time.
Hint: To comment and uncomment code easily (I'm not sure how this works in
Access 2007), open the VBA editor, right-click a blank area on the toolbar,
and click Customize. Click the Commands tab, and click Edit on the right.
On the left, find Comment Block and Uncomment Block, and drag these onto the
toolbar or onto a menu. Click Close. Select a block of code and click the
Comment Block icon or menu item. Use Uncomment block to reverse this.
Beats commenting the lines one at a time. These should be default menu or
toolbar items, but don't seem to be from what I can tell.


"Rachel Garrett" wrote in message
...
I have a form with two subforms that was working fine until a few
hours ago. Now, when I open up the form, I get this error message
every time I open it, try to move to a new record, or do anything else
besides scroll through the subforms:

"The expression On Current you entered as the event property setting
produced the following error: Object or class does not support the set
of events.

* The expression may not result in the name of a macro, the name of a
user-defined function, or [Event Procedure].
* There may have been an error evaluating the function, event, or
macro."

Now, I haven't changed any properties of any controls or labels,
except for changing one box to 16-point font instead of 8-point font.
I haven't changed properties of anything else either, to my knowledge.
Maybe it was a misplaced keystroke.

I would like to know how I get back to the event property setting and
change it to the default value. How can I get there?

Thanks,
Rachel


  #3  
Old April 21st, 2008, 08:18 PM posted to microsoft.public.access.forms
Rachel Garrett
external usenet poster
 
Posts: 41
Default Access says I entered an event property for On Current, but Ididn't.

I figured it out -- I must have hit the Form Selector when I was
dragging and rearranging my subforms. [Event Procedure] was the first
selection in the first property box that can be changed.
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 12:12 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.