INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

Troubleshooting

Having Trouble Getting Your Events to Work At All? by Sameal
Posted: 11 Jan 02

I have seen this several times and now I have also seen someone asking about it. It occurs when you have set up a form incorrectly at any step along the way. The reason for this also lies in the roots of programming. The error you will receive follows:

The expression On Load you entered as the event property setting produced the following error:  Member already exists in an object module from which this object module derives.  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 funciton, event or macro.

Basically if you switch to the VBA code window and begin to add events to a form manually without using the properties window of a form you will quickly get the error above.

Even if you've been making the events correctly all the way to the form and on the last one you decide to do manually. You just ruined that form. I have yet figured out how to reverse this process, but it can easily be avoided by ALWAYS using the Events tab in the Control Properties in Design View.

The reason for this is because in most higher-level languages you must link controllers to all of your controls. Not only do you have to define the form, the controls, their events, but you also must define the controllers that fire those events. In Access the controller creation is done for you everytime you go into Properties -> Events and create an event. You'll notice that it adds the framework to the sub-routine into the code for you. If you try and skip this properties dialog and move straight to code, you will not have the important controller built for you and therefore nothing will be listening to that button.

Back to Microsoft: Access Forms FAQ Index
Back to Microsoft: Access Forms Forum

My Archive

Resources

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close