Hallo,
we are using the Xchange Viewer to print pdf silent (without being shown).
Is there a way to select the printers tray programmatically?
select printer tray
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- Site Admin
- Posts: 7370
- Joined: Wed Mar 25, 2009 10:37 pm
Re: select printer tray
Hi Fanski,
thanks for the post.
Selecting the printer tray in a print job is not a part of the PDF-XChange SDK. It is a Windows function and part of their API. Take a look on the MSDN site for how to do this programmatically. I just did a search of MSDN for the terms "select printer tray" and got this example as the 3rd hit: http://social.msdn.microsoft.com/Forums ... 143540e2c/
There are copious examples and information available through MSDN and other web resources on how to do this. As I say it is not specific to our software or SDKs.
I hope that helps.
Sincerely
thanks for the post.
Selecting the printer tray in a print job is not a part of the PDF-XChange SDK. It is a Windows function and part of their API. Take a look on the MSDN site for how to do this programmatically. I just did a search of MSDN for the terms "select printer tray" and got this example as the 3rd hit: http://social.msdn.microsoft.com/Forums ... 143540e2c/
There are copious examples and information available through MSDN and other web resources on how to do this. As I say it is not specific to our software or SDKs.
I hope that helps.
Sincerely
Best regards
Paul O'Rorke
PDF-XChange Support
http://www.pdf-xchange.com
Paul O'Rorke
PDF-XChange Support
http://www.pdf-xchange.com
-
- User
- Posts: 33
- Joined: Tue Apr 17, 2012 10:33 am
Re: select printer tray
Thank you for the answer.
Im not sure what to do.
I’m using AxCoPdfxCview.PrintDocument(… (XChange Viewer method
for printing.
With AxCoPdfxCview.SetProperty("Print.PrinterName", printerName, 0);
I select the Printer.
I don’t have a PrintDocument object that is needed in the example you posted.
Im not sure what to do.
I’m using AxCoPdfxCview.PrintDocument(… (XChange Viewer method
for printing.
With AxCoPdfxCview.SetProperty("Print.PrinterName", printerName, 0);
I select the Printer.
I don’t have a PrintDocument object that is needed in the example you posted.
-
- Site Admin
- Posts: 7370
- Joined: Wed Mar 25, 2009 10:37 pm
Re: select printer tray
Hi Fanski,
you can use our Simple Viewer SDK. Do this:
1. obtain the printer's device context and prepare it as you need
(setup tray and any other needed parameters in DEVMODE) (Windows API part)
There is some good stuff here for this: http://msdn.microsoft.com/en-us/library ... 85%29.aspx
2. use PXCV_DrawPageToDC to print the specified page to your printer.
hth
you can use our Simple Viewer SDK. Do this:
1. obtain the printer's device context and prepare it as you need
(setup tray and any other needed parameters in DEVMODE) (Windows API part)
There is some good stuff here for this: http://msdn.microsoft.com/en-us/library ... 85%29.aspx
2. use PXCV_DrawPageToDC to print the specified page to your printer.
hth
Best regards
Paul O'Rorke
PDF-XChange Support
http://www.pdf-xchange.com
Paul O'Rorke
PDF-XChange Support
http://www.pdf-xchange.com
-
- User
- Posts: 33
- Joined: Tue Apr 17, 2012 10:33 am
Re: select printer tray
This looks like what i’m looking for.
I will try this out.
Thank you very much.
I will try this out.
Thank you very much.
-
- Site Admin
- Posts: 19913
- Joined: Mon Jan 12, 2009 8:07 am
Re: select printer tray
Our pleasure Fanski,
Please do let us know how your testing goes!
Cheers,
Stefan
Please do let us know how your testing goes!
Cheers,
Stefan