How can I know user click discard or save when close the document?

How can I know user click discard or save when close the document?

Anonymous
550 Views
3 Replies
Message 1 of 4

How can I know user click discard or save when close the document?

Anonymous
Not applicable

I have a problem. I use AutoCAD 2010. I want  to know the use click save or discard button when close the document. I know the "Saved" Property of  AcadDocument can tell me the result. However, I could not use the AcadDocument Class. Because there is another plug-in, when i use the com class just like AcadDocument , it will tell some error.so i only can use .net Class just like Document. Is there any Proprty to get it ?

0 Likes
Accepted solutions (1)
551 Views
3 Replies
Replies (3)
Message 2 of 4

hgasty1001
Advisor
Advisor

Hi,

 

Use some document and/or database event to do that. see the docs on events both database and document .

 

Gaston Nunez

 

 

0 Likes
Message 3 of 4

Anonymous
Not applicable

Thanks for your reply!Can you give me some more information?

0 Likes
Message 4 of 4

Anonymous
Not applicable
Accepted solution

I think i have get the answer.

I use Application.GetSystemVariable("DBMOD"). when it is return 0  it is saved and when return 5 is discard 

Thanks!

0 Likes