I have to check if I need to update an external reference in AutoCAD before I check-in into Vault
through the AutoCAD Vault-Client.
I know how to access the "normal" properties from an external reference by .NET.
static public void start()
Document doc = Application.DocumentManager.MdiActiveDocument;
Database db = doc.Database;
Editor ed = doc.Editor;
using (Transaction tr = db.TransactionManager.StartTransaction())
BlockTable table = tr.GetObject(db.BlockTableId, OpenMode.ForRead) as BlockTable;
foreach (ObjectId id in table)
BlockTableRecord record = tr.GetObject(id, OpenMode.ForRead) as BlockTableRecord;
....//here I want to get the special properties from Vault like checkedIn, refreshFile etc.
I have to access the Vault states through the Reference Manager in AutoCAD and to update the reference if the red arrows are displayed.
If you don't know what I mean, maybe the attached picture will help.
Solved! Go to Solution.
To be more precise...
We are working with AutoCAD 2013 and Vault Professional 2013.
I'm using C#, .NET 4.0
After having analyzed the XRef with the MgdDbg - SnoopEntities Tool I'm not sure If
I can get this special Vault Xref-Properties through AutoCAD and the Reference Manager. I have to find out how the
Vault AutoCAD PlugIn and the Vault-Explorer are working together and when this sign with the red arrows appears.
In this case, it seems like Vault and AutoCAD are highly interconnected.
Please keep in mind that checking in files for CAD applications like AutoCAD using the Vault API is unsupported. (need to use the AutoCAD Vault Plug-In to checkin CAD files)
Those Red arrows mean this. (From the Vault Help)
"The local copy of the file does not match the latest version in the vault. Use the Refresh from Vault feature to obtain the latest version of the file".
Using the API for Vault 2014 you can get the status Icon. This Blog post describes how this can be done.
I have a Vault 2014 VB standalone exe that uses this approach (EntityStatusImageInfo) to get the "status" of a file. Let me know if you want it.
I have not found a way to get the status in Vault 2013 versions. There is a FileStatus property for the file object in the Document Service but in my tests with Vault Pro this is always unknown.
This DevBlog post could be of interest:
thank you so much! That is good news. We will move to Vault Professional 2014 round about a month. So now I can spent the time to read the blog to get prepared. I think thirst I should try it on my own. If my problem still persists, I'll come back to your offer.
Have a nice day,
Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register
Start with some of our most frequented solutions to get help installing your software.