Hi there,
I have to know, if the user called "Save" or "Save as Copy".
Therefore I registered the events e_operBeforeExecute,and e_operExecuted,
But if the user executes the command from file menür or via icon, only the events e_document_beforeSave and later e_document_afterSave get raised.
How do I detect which command got called?
(Version 6.0.322.4)
Best regards,
cew
How toi detect which operation will be/was executed?
Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan
Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: How toi detect which operation will be/was executed?
Hello cew,
You can always make a custom command handler as listener for that:
https://gist.github.com/Polaringu/16bb2 ... 7cbe36f4e6
Cheers,
Alex
You can always make a custom command handler as listener for that:
https://gist.github.com/Polaringu/16bb2 ... 7cbe36f4e6
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Re: How toi detect which operation will be/was executed?
Hi Alex,
to be honest, I don't want to create an own command handler. That would be a bit overpowered for just getting the info, which command got executed.
How do I get the existing events e_operBeforeExecute,and e_operExecuted?
Best regards,
cew
to be honest, I don't want to create an own command handler. That would be a bit overpowered for just getting the info, which command got executed.
How do I get the existing events e_operBeforeExecute,and e_operExecuted?
Best regards,
cew
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: How toi detect which operation will be/was executed?
Hello cew,
On the other hand, you can use the https://sdkhelp.pdf-xchange.com/vie ... beforeSave event's IPXV_DocSaveEvent interface to check the https://sdkhelp.pdf-xchange.com/vie ... vent_Flags for PXV_DocSave_Copy flag. That should do it.
Cheers,
Alex
On the other hand, you can use the https://sdkhelp.pdf-xchange.com/vie ... beforeSave event's IPXV_DocSaveEvent interface to check the https://sdkhelp.pdf-xchange.com/vie ... vent_Flags for PXV_DocSave_Copy flag. That should do it.
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Re: How toi detect which operation will be/was executed?
Hi Alex,
could you please provide me a line of c# code on how to get that flag out of an AxPDFXEdit._IPXV_ControlEvents_OnEventEvent object?
Thank you!
Best regards,
cew
could you please provide me a line of c# code on how to get that flag out of an AxPDFXEdit._IPXV_ControlEvents_OnEventEvent object?
Thank you!
Best regards,
cew
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: How toi detect which operation will be/was executed?
Hello cew,
I've provided links that have detailed explanation on the interfaces casting and the properties that should be used.
The cast will look somewhat like this (though your interfaces should be used):
Cheers,
Alex
I've provided links that have detailed explanation on the interfaces casting and the properties that should be used.
The cast will look somewhat like this (though your interfaces should be used):
Code: Select all
PDFXEdit.IPXV_BeforeShowContextMenuEvent evt = (PDFXEdit.IPXV_BeforeShowContextMenuEvent)e.pEvent;
Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Re: How toi detect which operation will be/was executed?
Got it to work, thank you!
Best regards,
cew
Best regards,
cew
-
- User
- Posts: 5522
- Joined: Fri Nov 21, 2014 8:27 am
- Contact:
Re: How toi detect which operation will be/was executed?
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ