Own Print and Print Preview dialog
Moderators: TrackerSupp-Daniel, Tracker Support, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan
Own Print and Print Preview dialog
How can print/print preview document with AX Viewer but with own print dialog?
What code can we use to do this without UI of Exchange Viewer AX Control?
Thank you in advance,
Stoil
What code can we use to do this without UI of Exchange Viewer AX Control?
Thank you in advance,
Stoil
- Tracker Supp-Stefan
- Site Admin
- Posts: 17948
- Joined: Mon Jan 12, 2009 8:07 am
- Location: London
- Contact:
Re: Own Print and Print Preview dialog
Hi Stoil,
I am not 100% sure this will work - but you need to capture the event that the user is starting the printing process - cancel the dialogue, and then display your own.
After that - you can print via call to the core of the Viewer AX without further User inteaction with our own print dialogue:
"How to Print a Document"
This topic might also be useful:
https://forum.pdf-xchange.com/ ... 08&p=52345
Regards,
Stefan
I am not 100% sure this will work - but you need to capture the event that the user is starting the printing process - cancel the dialogue, and then display your own.
After that - you can print via call to the core of the Viewer AX without further User inteaction with our own print dialogue:
"How to Print a Document"
This topic might also be useful:
https://forum.pdf-xchange.com/ ... 08&p=52345
Regards,
Stefan
Re: Own Print and Print Preview dialog
Thank you, Stefan about fast answer.
It seems that I cant use AX Viewer control to do my own print process.
If I want to have my own print preview, I have to be able to print Page by Page and have method like :
[DllImport("pxcview")]
public static extern int PXCV_DrawPageToDC(IntPtr hDoc, Int32 page_num, IntPtr hDC, ref PXV_CommonRenderParameters pParams);
Have to use pxcview.dll for this?
Buying PDF-XChange Viewer SDK maybe only this DLL gives me own printing possibility???
Or We have to buy and another SDK ?
Regards,
Stoil
It seems that I cant use AX Viewer control to do my own print process.
If I want to have my own print preview, I have to be able to print Page by Page and have method like :
[DllImport("pxcview")]
public static extern int PXCV_DrawPageToDC(IntPtr hDoc, Int32 page_num, IntPtr hDC, ref PXV_CommonRenderParameters pParams);
Have to use pxcview.dll for this?
Buying PDF-XChange Viewer SDK maybe only this DLL gives me own printing possibility???
Or We have to buy and another SDK ?
Regards,
Stoil
-
- User
- Posts: 14
- Joined: Wed Sep 17, 2014 7:40 am
- Location: Ukraine
Re: Own Print and Print Preview dialog
You can't use ActiveX for render pages of the document to your own DC.
But you can use pxcview.dll for that task.
That DLL allow you to open PDF document and render any page to your own DC (and for your own printer too).
PDF-XChange Viewer Simple DLL SDK included into PDF-XChange Viewer SDK
For example of usage you can look into pxcview sample.
But you can use pxcview.dll for that task.
That DLL allow you to open PDF document and render any page to your own DC (and for your own printer too).
PDF-XChange Viewer Simple DLL SDK included into PDF-XChange Viewer SDK
For example of usage you can look into pxcview sample.
- Tracker Supp-Stefan
- Site Admin
- Posts: 17948
- Joined: Mon Jan 12, 2009 8:07 am
- Location: London
- Contact:
Re: Own Print and Print Preview dialog
Hi Stoil,
I assumed you just want a custom print preview dialogue, and then let the Viewer handle the rest of the printing.
Otherwise - just as Serg suggests - use the Viewer Simple DLL SDK to render to a DC!
Regards,
Stefan
I assumed you just want a custom print preview dialogue, and then let the Viewer handle the rest of the printing.
Otherwise - just as Serg suggests - use the Viewer Simple DLL SDK to render to a DC!
Regards,
Stefan
Re: Own Print and Print Preview dialog
Thank you, Serg & Stefan.
I want to make own Print Preview Dialog using System.Windows.Forms.PrintPreviewControl and System.Drawing.Printing.PrintDocument of C# .Net
I can't imagine how to implement your idea Stefan.
I do want to do print preview with little effort. But I do not see how to do this with AX Viewer Control.
And that's why I ask if there is a way to do this with AX Viewer and if there is not a way, I will do preview with xcview.dll, using C# sample.
If I can use print preview dialog of AX Viewer in Bulgarian and Russian language, it will be the best!
Regards,
Stoil
I want to make own Print Preview Dialog using System.Windows.Forms.PrintPreviewControl and System.Drawing.Printing.PrintDocument of C# .Net
I can't imagine how to implement your idea Stefan.
I do want to do print preview with little effort. But I do not see how to do this with AX Viewer Control.
And that's why I ask if there is a way to do this with AX Viewer and if there is not a way, I will do preview with xcview.dll, using C# sample.
If I can use print preview dialog of AX Viewer in Bulgarian and Russian language, it will be the best!
Regards,
Stoil
- Vasyl-Tracker Dev Team
- Site Admin
- Posts: 2353
- Joined: Thu Jun 30, 2005 4:11 pm
- Location: Canada
Re: Own Print and Print Preview dialog
Hi Stoil.
If you want to use printing process by Viewer ActiveX but with your own print-dialog - you may add in your UI the own 'Print' button, then, when user clicked on that - show your own print-dialog, fill our global print-parameters and then call our pdfControl.PrintDocument(... PXCVA_NoUI);
HTH.
If you want to use printing process by Viewer ActiveX but with your own print-dialog - you may add in your UI the own 'Print' button, then, when user clicked on that - show your own print-dialog, fill our global print-parameters and then call our pdfControl.PrintDocument(... PXCVA_NoUI);
HTH.
Vasyl Yaremyn
Tracker Software Products
Project Developer
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Tracker Software Products
Project Developer
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Re: Own Print and Print Preview dialog
Thank you, Vasil.
I intend to do this about printing. But I have problem with implementing print preview.
We have program with UI in 3 different languages and I have to show print preview dialog with localization of these languages.
That's why I ask about opportunity of doing this with Viewer ActiveX.
Can I localizate print preview dialog of Viewer to other languages?
or
Can I use some code of Viewer to do own print preview?
or
I have to use Viewer Sipmle PDF DLL SDK using the code from pxcview sample?
Regards,
Stoil
I intend to do this about printing. But I have problem with implementing print preview.
We have program with UI in 3 different languages and I have to show print preview dialog with localization of these languages.
That's why I ask about opportunity of doing this with Viewer ActiveX.
Can I localizate print preview dialog of Viewer to other languages?
or
Can I use some code of Viewer to do own print preview?
or
I have to use Viewer Sipmle PDF DLL SDK using the code from pxcview sample?
Regards,
Stoil
- Vasyl-Tracker Dev Team
- Site Admin
- Posts: 2353
- Joined: Thu Jun 30, 2005 4:11 pm
- Location: Canada
Re: Own Print and Print Preview dialog
Hi, Stoil.
http://msdn.microsoft.com/en-us/library ... 85%29.aspx
HTH.
Sure, you can. Look to <AppFolder>/Languages/ and create and fill your own PDFXVW_<langID>.xml file. Note: this file shoud contain the special and unique value for attribute lcid. You may take your lcid value from there:Can I localizate print preview dialog of Viewer to other languages?
http://msdn.microsoft.com/en-us/library ... 85%29.aspx
HTH.
Vasyl Yaremyn
Tracker Software Products
Project Developer
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Tracker Software Products
Project Developer
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.