when I asked about this a long time ago, I was told that ther is no such thing in openoffice and I should use the api of the language to do this.
for example if you are using java, use the java-api for finding the printers
the code below might help you if you are using java
public String[] getDefinedPrintersOnServer(){
PrintService[] printers = printServiceLookup.lookupPrintServices(null,null);
  String[] data = new String[printers.length];
  for(int i=0; i<printers.length; i++){
    data[i] = printers[i].getName();
  }
  return data;
}

to be able to use these printers in openoffice (in va 1.1.x atleast, hav enot checked with the 1.9 series) you might have to add < and > around the name... so if you get "Hp color jet" from the system call, to be able to use it in openoffice you might have to supply the name "<Hp color jet>"

/Christian Andersson

Turbo Fredriksson wrote:
I'm able to retrieve the setup of the _current_ printer
using getPrinter(), but how do I get a list of _all_
printers that exists (on the system naturally :)?

Can't seem to find something like getPrinters() or printerList() :)

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to