Mike Hughes
Registered User.
- Local time
- Today, 15:00
- Joined
- Mar 23, 2002
- Messages
- 493
When I run this event procedure :
Private Sub Command1_Click()
'Search for Specific Name in the "Name" field
On Error GoTo Err_Command1_Click
Dim strLen, i As Integer
Dim strTempName, strSearchName As String
strLen = Len(strSearchName)
DoCmd.GoToControl "Name"
strSearchName = InputBox("Enter Member Name.", "Look Up Name")
DoCmd.FindRecord strSearchName, acAnywhere, , acSearchAll, , acCurrent, True
Exit_Command1_Click:
Exit Sub
Err_Command1_Click:
MsgBox Err.Decription
Resume Exit_Command1_Click
'MsgBox "Cancelled"
'Resume Exit_Command102_Click
End Sub
If I don't enter a name and click ok or cancel I get a runtime error # 438. Object doesn't support this property of method.
When I debug it highlights this line
MsgBox Err.Decription
Can someone tell me what is wrong?
Thanks
Private Sub Command1_Click()
'Search for Specific Name in the "Name" field
On Error GoTo Err_Command1_Click
Dim strLen, i As Integer
Dim strTempName, strSearchName As String
strLen = Len(strSearchName)
DoCmd.GoToControl "Name"
strSearchName = InputBox("Enter Member Name.", "Look Up Name")
DoCmd.FindRecord strSearchName, acAnywhere, , acSearchAll, , acCurrent, True
Exit_Command1_Click:
Exit Sub
Err_Command1_Click:
MsgBox Err.Decription
Resume Exit_Command1_Click
'MsgBox "Cancelled"
'Resume Exit_Command102_Click
End Sub
If I don't enter a name and click ok or cancel I get a runtime error # 438. Object doesn't support this property of method.
When I debug it highlights this line
MsgBox Err.Decription
Can someone tell me what is wrong?
Thanks