.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

i want to get the name of the user who edit the drawing last time

3 REPLIES 3
Reply
Message 1 of 4
hoyin0820
358 Views, 3 Replies

i want to get the name of the user who edit the drawing last time

but i do not get any idea to do this

 

 

anyone know that and teach me plz 

3 REPLIES 3
Message 2 of 4
norman.yuan
in reply to: hoyin0820

By default, when a drawing is saved, AutoCAD does not save current user's name with the drawing as file property. Therefore, you have no way to know who is the last user who has changes being saved in the drawing unless you do something during the period when drawing is open in AutoCAD: when drawing is opened, saved and/or closed...

 

The obvious option is to use drawing custom properties (DatabaseSummaryInfo in .NET API, there is eqivalent in VBA, too). You can save user name in DatabaseSummaryInfo whenever drawing is (to be) saved or to be closed.

 

Of course in this case, you can only read the "last user" information when the drawing is opened in AutoCAD, or at least when AutoCAD is running and you load the drawing as side database.

 

If you store the drawing is some sort of document management system (such as something based on SharePoint), then there must be some kind of custom saving command, which can save more file meta information, including who is the last user, together with the drawing file. Then you can get these kind of meta information without opening a drawing file in AutoCAD.

Norman Yuan

Drive CAD With Code

EESignature

Message 3 of 4
jeff
in reply to: norman.yuan

Do not know if changed in a certain year or a system variable but whenever a file is saved in Vanilla 2013 it updates the Last saved by in Database Summary info.

 

 

 

You can also find your answers @ TheSwamp
Message 4 of 4
hoyin0820
in reply to: hoyin0820

ok thx

 

and i want to get another information on the drawing such as Text Font, Heights, Widths and line weights

 

i using thsdrawing.activetextstyle.fontfile it only can get the last one text font, it cannot get all text font on the drawing

 

what can i do ?

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost