Page 1 of 1

WinForms - How to continously add Annotations

Posted: Sun Apr 22, 2018 12:57 pm
by farangkao
Hi there,

i'm currently testing your Product as a possible replacement for our old library.

Everything looks very good so far, your Library is really well done.

However i struggle to implement in Code the behavior that we had before:
if the user set a Mode (like "Add Lines") ,he can add lines until he switches the Mode to "Selection" or similar.

I've tried to use the Method PdfAnnotationTool.AddAndBuildAnnotation(annotation);

Which works so far. I figured i call this Method after the Event "BuildingFinished" has fired.

But: When i press Escape and i call the AddAndBuildAnnotation again in Code, the Application crashes.

System.ArgumentOutOfRangeException in Vintasoft.Imaging.dll

I then tried to figure out what circumstances this is comming from.
I noticed that the Event AnnotationViewChanged is called twice with RemoveItem just before the crash.
So i presume that is the root cause.

What is the Proper way ,to achieve my goal, so that the user doesn't has to click the command multiple times to draw/add annotations?

Is there a better Event to subscribe to, so it doesn't interfere with the Interaction?

Re: WinForms - How to continously add Annotations

Posted: Mon Apr 23, 2018 11:29 am
by Alex
Hello,

Please send us (to support@vintasoft.com) a small working application, which demonstrates your problem. We need analyze your code.

Best regards, Alexander

Re: WinForms - How to continously add Annotations

Posted: Thu Apr 26, 2018 2:30 pm
by farangkao
This has been sucessfully fixed in the newest Version, thanks again.