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

Project Navigator and Sheet Sets in AutoCAD Architecture 2010

1 REPLY 1
Reply
Message 1 of 2
s.jabs
724 Views, 1 Reply

Project Navigator and Sheet Sets in AutoCAD Architecture 2010

Anyone have any success programatically updating the Sheet Set data with the Project Navigator configuration?

My office uses a custom program to create project directories, update our Intranet-based project list, and populate the Project Navigator .apj (text) file. However, I'm unable to edit the Sheet Set file (.dst) because it's in a compiled format. The Sheet Set file thus has the standard text entries in it, and whenever a user edits the project, he/she has to deal with that ugly "Project Navigator and the Sheet Set Manager are out of sync" prompt, which I'd like to avoid.

From within AutoCAD Architecture, I can access the Sheet Set data with Lee Ambrosius's COM code (see his AU 2009 CP318-4 class), but when I make changes this way, Project Navigator complains it cannot access the data as it may have been editted elsewhere. Closing Project Navigator and reopening it fixes this, but only when you do it manually (i.e.: a SendStringToExecute call doesn't work).

I've been fooling around with the AecProjectBaseMgd .NET library, but can't figure out a way to access the Sheet Set data from there.

So I'd either like to edit the .dst file from outside of AutoCAD, or figure out a way to update the data on certain events (such as after selecting a project in ProjectBrowser).
1 REPLY 1
Message 2 of 2
pavlukas
in reply to: s.jabs

Look library COM ->AcSmComponents17 1.0 Type Library

using ACSMCOMPONENTS17Lib
AecXProject 5.7 Type Library

ProjectBaseManager mgr = ProjectBaseServices.Service.ProjectManager;
string currentPath = mgr.CurrentProjectFileName.Location;
Project proj = mgr.OpenProject(OpenMode.ForRead, currentPath, mgr.CurrentProjectFileName.Name, true);
AcSmSheetSetMgr SheetSetMgr = new AcSmSheetSetMgr();
AcSmDatabase db = SheetSetMgr.FindOpenDatabase(currentPath + mgr.CurrentProjectFileName.Name + ".dst");
AcSmSheetSet SheetSet = db.GetSheetSet();
IAcSmEnumComponent comp = db.GetSheetSet().GetSheetEnumerator();

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