Hello! Leon here! I have a button which, when pressed, prints out details of the person's record, identified by their ID code. It works perfectly, except it shows the printer dialogue box - which I do not want the user to see. The question is, how do I stop the dialogue box from appearing. I am using Warnings and Echo !!?? And I have made an adjustment in the Options facility. Thank you.
Code:
Private Sub PrintContactDetails_Click()On Error GoTo PrintContactDetails_Click_Err
DoCmd.Echo False, ""
DoCmd.SetWarnings False
DoCmd.RunMacro "PrintReportNew", , ""
DoCmd.SetWarnings True
DoCmd.Echo True, ""
PrintContactDetails_Click_Exit:
Exit Sub
PrintContactDetails_Click_Err:
MsgBox Error$
Resume PrintContactDetails_Click_Exit
End Sub.....