Dyego Souza Dantas Leal a écrit :
> Exists a example to "print a document" using the OfficeBean ( java
> language )
>
> Using directly access is:
>
> protected void printDocComponent(XComponent xDoc) throws
> java.lang.Exception {
> XPrintable xPrintable = (XPrintable)UnoRuntime.queryInterface(
> XPrintable.class, xDoc);
> PropertyValue[] printerDesc = new PropertyValue[1];
> printerDesc[0] = new PropertyValue();
> printerDesc[0].Name = "Name";
> printerDesc[0].Value = aPrinterName;
>
> xPrintable.setPrinter(printerDesc);
> PropertyValue[] printOpts = new PropertyValue[1];
> printOpts[0] = new PropertyValue();
> printOpts[0].Name = "Pages";
> printOpts[0].Value = "1";
> xPrintable.print(printOpts); }
>
>
> in OfficeBean case ... how to print a document ?
In the same way. The OfficeBean is simply a way to integrate the
OpenOffice.org window inside a Java application.
Hope this helps,
Cedric
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]