error On Click

T

Toni B

I created a form for my database with a few command buttons that I added from
the toolbox - add record, find record, close form, quit application. They
were working fine but then today I started getting this same error message
for all of them:
the expression On Click you entered as the event property setting produced
the following error: Ambiguous name detected: Quit_application_Click
- 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.

I've tried compacting and repairing the database but that hasn't helped. Any
other suggestions?
I suspect that the properties of the command buttons have got screwed up but
I have no idea what they're supposed to say.
Thanks out there in cyberland.
 
A

Allen Browne

Open the form's module, and look at the code.

Sounds like you have two procedures there, both named
Quit_application_Click.

Delete one of them to solve the Ambigous name error.
 
T

Toni B

Thanks Allen. Unfortunately I don't know how to open the form's module and
look at the code. I understand what you mean though.
I've just created a second database into which I copied my table, and
created a new form from scratch. seems to have worked okay.

Allen Browne said:
Open the form's module, and look at the code.

Sounds like you have two procedures there, both named
Quit_application_Click.

Delete one of them to solve the Ambigous name error.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Toni B said:
I created a form for my database with a few command buttons that I added
from
the toolbox - add record, find record, close form, quit application. They
were working fine but then today I started getting this same error message
for all of them:
the expression On Click you entered as the event property setting produced
the following error: Ambiguous name detected: Quit_application_Click
- 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.

I've tried compacting and repairing the database but that hasn't helped.
Any
other suggestions?
I suspect that the properties of the command buttons have got screwed up
but
I have no idea what they're supposed to say.
Thanks out there in cyberland.
 
Top