Printer Name/Port problem - Win 7 eXcel 2003

About the programming interface for the virtual PDF printer driver.

Moderator: jr

Printer Name/Port problem - Win 7 eXcel 2003

Postby techedgeau » Thu Jan 20, 2011 10:08 am

Using eXcel 2003 on Win-7, I'm trying to print to the BullZip printer, which installs on port BULLZIP. When trying to set "ActivePrinter" I get Run-time error '1004'.
The eXcel VBA code below works for CutePDF when I have the line:

ActivePrinter ="CutePDF Writer on CPW2:

but when I use

ActivePrinter = "Bullzip PDF Printer on BULLZIP"

.. I get the error 1004. Here's my "working" code, but commented to use the BullZip printer which WIn-7 tells me is installed on port BULLZIP, whereas my CutePDF is on port CPW2:
Public Sub Print_PDF()
Dim sCurrentPrinter As String
sCurrentPrinter = ActivePrinter
'-----ActivePrinter = "CutePDF Writer on CPW2:" '<--- works!
ActivePrinter = "Bullzip PDF Printer on BULLZIP" '<--- BROKEN!!!
ActivePrinter = sCurrentPrinter
End Sub
I'm sure there's a simple explanation? Sems to me the port is not correct.
I even thought to use the code at to see if that gave me any inspiration, but of course the results do not mention the (necessary) port at all! Anyway, here's the output showing the CutePDF and BullZip lines returned by that code:
There are 5 local and connected printers.
Printer: Bullzip PDF Printer Server: Attributes: 240
Printer: CutePDF Writer Server: Attributes: 240

Any ideas?
Posts: 1
Joined: Thu Jan 20, 2011 8:52 am

Return to Programming

Who is online

Users browsing this forum: No registered users and 1 guest