Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

My buttons dont work!!??

Status
Not open for further replies.

mattpearcey

Technical User
Mar 7, 2001
302
GB
With my main form, i have placed a series of command buttons, i.e. search, navigator, open form, save, delete, etc, in the footer area. They have been working fine, up until now. As the database as developed, the buttons are now not working and the follwing error message comes up. "The expression On Click you entered as the event property setting produced the following errod:Ambiguous name detected: Open_comments_form_Click. *The expression may not result in the name of the macro, the name of the user-deined function or [Event Procedure] *There may have been an error evaluating the function, event, or macro.

Any ideas on how to rectify? Tried deleting the action buttons and then putting them in again, but same error comes up again. Its in 97 version.

Much appreciate all the help.

Kind regards

Matt
 
Your first post said the code that didnt work was
*************************************
Private Sub CPC_Information_Click()
On Error GoTo Err_CPC_Information_Click

Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "F_CPCData"

stLinkCriteria = "[PIN]=" & Me![PIN]
DoCmd.OpenForm stDocName, , , stLinkCriteria

Exit_CPC_Information_Click:
Exit Sub

Err_CPC_Information_Click:
MsgBox Err.Description
Resume Exit_CPC_Information_Click

End Sub

***********************************

Is that still the name of the button that doesn't work? That name is no longer in the code you last posted. Zorro
 
I've tried changing the name, hoping that somehow, that might unconfuse the database. I try to keep the names similar. The form that I am having the problem with is F_CPCData.

The code with the form F_Meeting Data is for the button that works correctly.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top