Compile Error help needed please

pascaly

Registered User.
Local time
Tomorrow, 07:48
Joined
Jan 29, 2008
Messages
28
HI,

I have no doubt this is something very straighforward I cannot see, but when I try to comile my Db, I get an error saying;
Compile Error: Label not defined.

I've checked through, but cannot find the problem, it tells me
"Resume Exit_cmdEndAfterCalendar_Click"
is the line causing problems, but I cannot see why, any ideas?

Code is:

Private Sub cmdEndAfterCalendar_Click()
On Error GoTo Err_cmdEndAfterCalendar_Click

Dim stDocName As String
Dim stLinkCriteria As String

DoCmd.OpenForm "frmCalendar", , , , , acDialog
If Not IsNull(gvarDate) And Not IsEmpty(gvarDate) Then
Me.txtEndingAfter = gvarDate
End If

Exit_cmdEndDateCalendar_Click:
Exit Sub

Err_cmdEndAfterCalendar_Click:
MsgBox Err.Description
Resume Exit_cmdEndAfterCalendar_Click

End Sub
 
you might want to replace "Exit_cmdEndAfterCalendar_Click" by " Exit_cmdEndDateCalendar_Click".
 
razdanrahul, perfect!

Thanks a lot for a very quick reply, made the change and now it's working fine.

Very much appreciated.
 

Users who are viewing this thread

Back
Top Bottom