How to delete annotation without confirmation message

PDF-XChange Editor SDK for Developers

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.
Post Reply
prasantha
User
Posts: 43
Joined: Fri Jun 24, 2022 8:15 am

How to delete annotation without confirmation message

Post by prasantha »

HI,
I have a requirement to delete the annotations silently. That is when I used the below code to delete the annotation.
image.png
When I ran the application, then it shows a confirmation message before deleting the annotation. The user has to confirm the delete operation to continue. But I don't want this confirmation message. Can anybody let me know how can I remove the confirmation message before delete?
zarkogajic
User
Posts: 1370
Joined: Thu Sep 05, 2019 12:35 pm

Re: How to delete annotation without confirmation message

Post by zarkogajic »

Hi,

Try using: "Op.Do(OpExecFlag_NoUI)"

-žarko
prasantha
User
Posts: 43
Joined: Fri Jun 24, 2022 8:15 am

Re: How to delete annotation without confirmation message

Post by prasantha »

HI žarko,

Thank you for your reply,
I tried it. But no luck. still, it shows the message box.
zarkogajic
User
Posts: 1370
Joined: Thu Sep 05, 2019 12:35 pm

Re: How to delete annotation without confirmation message

Post by zarkogajic »

HI,

Can you send a screen shot of that dialog?

p.s.
I do not get any dialogs when running that code.

-žarko
prasantha
User
Posts: 43
Joined: Fri Jun 24, 2022 8:15 am

Re: How to delete annotation without confirmation message

Post by prasantha »

Hi žarko,
It shows the below message.
image.png
image.png (51.96 KiB) Viewed 1162 times
The code i have used as below
image(1).png
zarkogajic
User
Posts: 1370
Joined: Thu Sep 05, 2019 12:35 pm

Re: How to delete annotation without confirmation message

Post by zarkogajic »

Hi,

Sorry, I cannot reproduce - for me that dialog does not display.

You'll have to wait for official support guys...

-žarko
zarkogajic
User
Posts: 1370
Joined: Thu Sep 05, 2019 12:35 pm

Re: How to delete annotation without confirmation message

Post by zarkogajic »

Hi ,

Out of curiosity: what is the type of annotation you are deleting?

-žarko
User avatar
Vasyl-Tracker Dev Team
Site Admin
Posts: 2352
Joined: Thu Jun 30, 2005 4:11 pm
Location: Canada

Re: How to delete annotation without confirmation message

Post by Vasyl-Tracker Dev Team »

We also cannot reproduce it. Seems you are using too old version of SDK that has this warning. Please try the latest version(363 build)...
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.
prasantha
User
Posts: 43
Joined: Fri Jun 24, 2022 8:15 am

Re: How to delete annotation without confirmation message

Post by prasantha »

I am using version 1.0,0.0, runtime version is v4.0.30319
image.png
And below shows the properties of if the pdfexditcore.dll
image(1).png
.


Further I found that this issue occurs only in some machines, this works as expected in others.
User avatar
Vasyl-Tracker Dev Team
Site Admin
Posts: 2352
Joined: Thu Jun 30, 2005 4:11 pm
Location: Canada

Re: How to delete annotation without confirmation message

Post by Vasyl-Tracker Dev Team »

Weird, we can't reproduce it at all. And also I checked the code history, up to 2019 - there is no (and never was) code that would show this message inside from op.Do()...

Please check your EditorEvent-handler - maybe you handle the e.operBeforeExecute event for op.annots.delete operation and show this msg?
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.
Post Reply