Error Settind Default Printer in VBA

V

Vassago

Hello,

When I try to run the following code in a macro:

Sub PrintToAnotherPrinter()

Dim STDprinter As String

STDprinter = Application.ActivePrinter

ActivePrinter = "Adobe PDF on Ne02"

End Sub


I am getting an error code that looks like this:

Microsoft Visual Basic
Red Cross "400"
OK Help

Help brings up a blank screen and OK just cancels the operation. Can
anyone help me with my code?

Thanks!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top