My code crashes when it gets to the msgbox line and i can't for the life of me see why! Any ideas ? If i step through the code it works fine. Thanx in advance for any help
Sub PrintReport()
On Error GoTo ErrHandler
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
MsgBox "The Customer Statement is now printing", vbInformation, "Printing........." ' crashes here
Unload fmLetter
fmMain.Show
Exit Sub
ErrHandler:
MsgBox "Error Printing Report", vbCritical, "Error"
Exit Sub
End Sub
Sub PrintReport()
On Error GoTo ErrHandler
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
MsgBox "The Customer Statement is now printing", vbInformation, "Printing........." ' crashes here
Unload fmLetter
fmMain.Show
Exit Sub
ErrHandler:
MsgBox "Error Printing Report", vbCritical, "Error"
Exit Sub
End Sub