Button to open form error

C

Christine

Tried to add a button to open a related form and get the
error... "The expression On Click you entered as the event
property setting produced the following error: ambiguous
name detected" What might be some solutions?
 
J

Jeff Conrad

Hi Christine,

Most likely this is because you have two subs or functions
defined somewhere with the same name. Access doesn't know
which one to use.

Most likely this is caused by creating a command button
that has a procedure attached to it, deleting the button
from the form, and then adding another one with the exact
same name. When you delete the button, Access is not very
good about cleaning up after itself and does not delete
the underlying procedure associated with the button.

Open the code window for the form and look around for two
(or more) procedures with the same name. Just delete the
extra lines of code you don't need. Then compile the code
to see if everything looks good now.

Hope that helps,
Jeff Conrad
Bend, Oregon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top