Peter

If I understand your question, APRINTERS(laPrinters) will create an array with 
two columns and the second column contains the port information that you need

You would presumable need something like

lcDest = laPrinters(n,1) + " on " + laPrinters(n,2)

HTH

Paul Newton

----- Original Message -----
From: "Peter Hart" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: 16 April 2008 12:36:34 o'clock (GMT) Europe/London
Subject: RE: Excel Automation

Hi All

 

I am using PDFCreator to convert an Excel Spreadsheet to PDF.

 

I am changing the Excel active printer with the code:

oleExcel.Application.ActivePrinter = "PDFCreator on Ne01:"

 

And then printing the sheet with the code:

oleExcel.ActiveWindow.SelectedSheets.PrintOut(,,1,,"PDFCreator on
Ne01:",,,)

 

This worked OK till one of the operators added a Network printer on Ne01
so I have had to change the above code to

 

oleExcel.Application.ActivePrinter = "PDFCreator on Ne00:"

oleExcel.ActiveWindow.SelectedSheets.PrintOut(,,1,,"PDFCreator on
Ne00:",,,)

 

Question:  Does anyone know of a way to find out the correct names of
the printers installed.  APRINTERS() only shows "PDFCreator"

 

I need a way to let the operator set the full printer name of the PDF
printer so the Computer He/She is using correctly prints to the right
printer.

I.e.  Pick the PDF Printer, Store its name in a Preferences Table and
then use that in the code.

 

TIA

 

Peter

Peter Hart Computers.

 

 



--- StripMime Report -- processed MIME parts ---
multipart/alternative
  text/plain (text body -- kept)
  text/html
---

[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to