BB code in posts seems to be working again!
I haven't turned on every single tag, so please let me know if there are any that are used/needed but not activated.

Main Menu

Visio C# and EventSink

Started by RodrigoCampos, March 20, 2012, 11:15:06 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


I implemented an Windows form with eventsink to detect "shapeDeleted" once I just could access to


but I wanna to access to the "afterShapeDeleted", but right now I have two problems:

1- The below code do not work

         pageEventList.AddAdvise((short)Microsoft.Office.Interop.Visio.VisEventCodes.visEvtCodeShapeDelete, eventHandler, "", "");

I'm getting this error:

         {"\n\nAn exception occurred."}

I already tried this(with no success):

         pageEventList.AddAdvise((short)801, eventHandler, "", "");

2- The following code is working, but I don't know how can I return back to my form code to perform some extra code, once the detection is made at "EventSink.cs" class and not on my "Form.cs":

pageEventList.AddAdvise((short)Microsoft.Office.Interop.Visio.VisEventCodes.visEvtShape         + (short)Microsoft.Office.Interop.Visio.VisEventCodes.visEvtDel, eventHandler, "", "");

There is anyway to catch the interruption on my Form.cs?

Thank you in advance,
Rodrigo Campos

Browser ID: smf (possibly_robot)
Templates: 4: index (default), Display (default), GenericControls (default), GenericControls (default).
Sub templates: 6: init, html_above, body_above, main, body_below, html_below.
Language files: 4: index+Modifications.english (default), Post.english (default), Editor.english (default), Drafts.english (default).
Style sheets: 4: index.css, attachments.css, jquery.sceditor.css, responsive.css.
Hooks called: 162 (show)
Files included: 34 - 1306KB. (show)
Memory used: 1047KB.
Tokens: post-login.
Cache hits: 13: 0.00142s for 26,767 bytes (show)
Cache misses: 2: (show)
Queries used: 16.

[Show Queries]