Hi,
We need to implement logging of printed documents in our application, but as far as I can see, there is no way to detect when the user has printed the open document. Can you please add a named notification (like the TextEditor::OnStart/OnStop notifications) for when the document has been sent to a printer, ie after OK in the print dialog?
Best Regards,
Kenneth Aafløy
In3 Support AS
Named notification for printing complete
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- User
- Posts: 18
- Joined: Tue Jun 17, 2008 3:37 am
-
- Site Admin
- Posts: 2448
- Joined: Thu Jun 30, 2005 4:11 pm
Re: Named notification for printing complete
This feature will be added into the next build (upcoming).
For this, you should catch OnEvent(PXCVA_OnNamedNotify, "Notifications.Print", ...)
For details, refer to "Reference\Named Items\Notifications\Print" in the new SDK Help file that will be updated for the new release.
For this, you should catch OnEvent(PXCVA_OnNamedNotify, "Notifications.Print", ...)
For details, refer to "Reference\Named Items\Notifications\Print" in the new SDK Help file that will be updated for the new release.
PDF-XChange Co. LTD (Project Developer)
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
-
- User
- Posts: 216
- Joined: Thu Jul 08, 2004 7:29 pm
Re: Named notification for printing complete
As a follow-on question, once the document has been printed, is there a way to find out what Pages of the document the user decided to print. I need to audit that the user printed the document (as compared to pressing Cancel within the print dialog) and what exact pages where printed. Further, the printer name would be nice but not necessary.
-
- Site Admin
- Posts: 5223
- Joined: Tue Jun 29, 2004 10:34 am
Re: Named notification for printing complete
Hi,
I am afraid we offer no specific mechanism to achieve this and unless you code some very restrictive interface or capture method its going to be very tough and cumbersome to achieve.
I am afraid we offer no specific mechanism to achieve this and unless you code some very restrictive interface or capture method its going to be very tough and cumbersome to achieve.
If posting files to this forum - you must archive the files to a ZIP, RAR or 7z file or they will not be uploaded - thank you.
Best regards
Tracker Support
http://www.tracker-software.com
Best regards
Tracker Support
http://www.tracker-software.com
-
- Site Admin
- Posts: 2448
- Joined: Thu Jun 30, 2005 4:11 pm
Re: Named notification for printing complete
Hi, DSSavant.
1. setup print-events filter:2. and catch the print-event:
HTH
You may:...I need to audit that the user printed the document (as compared to pressing Cancel within the print dialog) and what exact pages where printed.
1. setup print-events filter:
Code: Select all
SetProperty("Notifications.Print.Filter", -1, 0); // to listen all print-events
Code: Select all
OnEvent(Type:PXCVA_OnNamedNotify, Name:"Notifications.Print", ...)
{
if (Notifications.Print.Type == "EndPage")
{
GetProperty("Notifications.Print.PrinterName", prnName, 0);
GetProperty("Notifications.Print.Document", docId, 0); // document which printing
GetProperty("Notifications.Print.Page", pageIndex, 0); // page which printed
//
// collect obtained info into your history...
...
}
...
}
PDF-XChange Co. LTD (Project Developer)
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
-
- User
- Posts: 216
- Joined: Thu Jul 08, 2004 7:29 pm
Re: Named notification for printing complete
The Event catching method should work ... I hope. Thanks.
Allow me to suggest a few items for your next release:
- Ability to Audit user actions more closely and in a more streamline fashion. If at all possible, using OOPs paradigms.
- Printing, Rotating, Extraction, Page movement, etc. All changes to a document should be able to be audited. I would be willing to bet that people are using the SDK because they need this type of granularity as compared to simply embedding a PDF editor in their application.
-------------
As a follow-on, I noticed that when you call the Print Document function, it will throw if the user hits cancel. Pressing cancel is not an error condition so I would not expect it to throw. Maybe the routine should be returning something like a DialogResult instead?
Allow me to suggest a few items for your next release:
- Ability to Audit user actions more closely and in a more streamline fashion. If at all possible, using OOPs paradigms.
- Printing, Rotating, Extraction, Page movement, etc. All changes to a document should be able to be audited. I would be willing to bet that people are using the SDK because they need this type of granularity as compared to simply embedding a PDF editor in their application.
-------------
As a follow-on, I noticed that when you call the Print Document function, it will throw if the user hits cancel. Pressing cancel is not an error condition so I would not expect it to throw. Maybe the routine should be returning something like a DialogResult instead?