Undo glue

D

dani

Hi everyone

I have a COM-Addin which checks for each 1-D shape when glued to a 2-D
shape by the user, if it may be glued to that 2-D shape (according to
the rules in my database).

So in case operation was not allowed, how can I simply undo the user
action the way the 1-D connector looks the same as if it had never been
glued and moved (beginX, beginY, endX and endY restored)??

This is what I've tried so far:

- catch the "connection added" event and check in the database if glue
is possible.
- then, if not possible, I call "Application.Undo", but this never works
(why?).

Does anybody have a working solution for this or a good idea?

thanks for any help

Daniel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top