[AccessD] Compile Error - Label Not Defined

Kathryn at Gwen's kathrynatgwens at socal.rr.com
Thu Feb 27 13:52:56 CST 2014


Totally different mdb this time. I'm totally out of my bailiwick with making
print buttons. In the past, I've had no problem copying one, then modifying
it, compiling, and everything works. This time, I'm getting an error. First
is the one that works fine (* note at end).

- - - - - - - -
Private Sub btnBickleyFont_Click()
On Error GoTo Err_btnBickleyFont_Click

    Dim DocName As String

    DocName = "Envelope - Binkley Font"
    DoCmd.OpenReport DocName, A_PREVIEW

Exit_btnBickleyFont_Click:
    Exit Sub

Err_btnBickleyFont_Click:
    MsgBox Error$
    Resume Exit_btnBickleyFont_Click

End Sub
- - - - - - - -
Now the new one:
- - - - - - - -
Private Sub btnBickleyFontGwen_Click()
On Error GoTo Err_btnBickleyFontGwen_Click

    Dim DocName As String

    DocName = "Envelope - Binkley Font Gwen"
    DoCmd.OpenReport DocName, A_PREVIEW

Exit_btnBickleyGwenFont_Click:
    Exit Sub

Err_btnBickleyFontGwen_Click:
    MsgBox Error$
    Resume Exit_btnBickleyFontGwen_Click
End Sub
- - - - - - - -
That's the one that I get "Compile Error - Label Not Defined" - what does
that mean? How do I fix it?


-- 
Kathryn Bassett 
kathrynatgwens at socal.rr.com (work)
Kathryn at bassett.net (home)




(*) though recently, without any modification, it gives a blank envelope in
between printed envelopes. Livable, but baffling.


---
This email is free from viruses and malware because avast! Antivirus protection is active.
http://www.avast.com



More information about the AccessD mailing list