Hi,
I am working on an VBA module for Word 2000. When I assign a "wrong" printer name to
Application.ActivePrinter = "\\Server\Wrong Printer Name on SomePort:"
I get the error message 5216 "Printer Error". So far so good. But the usual
On Error GoTo 0
On Error Resume Next
doesn't work here.I just want to intercept this message to ask the user to select another printer or to quit.
Any ideas ?
Background: This is a little macro allowing to print some documents on a printer, which the user can select. As this can be a "special printer", like Fax or PDF, it would be nice, if the macro could "remember" the selection, which the user had made earlier. When it starts the macro will save the present printer selection (i.e. a "normal" paper printer) and restore that setting, when it terminates. The above event might happen, if a printer is not available anymore, e.g it might have been uninstalled.
Hans