AutoCAD Architecture Forum
Welcome to Autodesk’s AutoCAD Architecture Forums. Share your knowledge, ask questions, and explore popular AutoCAD Architecture topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Parsing DWG File

3 REPLIES 3
Reply
Message 1 of 4
Anonymous
2324 Views, 3 Replies

Parsing DWG File

I'd like to read an ACAD and ACA file using .NET, and extract all objects inside it with all attributes attached to any object. Please tell me if there is a differnce regarding reading ACA or ACAD files.
3 REPLIES 3
Message 2 of 4
Anonymous
in reply to: Anonymous

http://discussion.autodesk.com/forums/forum.jspa?forumID=152

--
Dean Saadallah
http://LTisACAD.blogspot.com
--
Message 3 of 4
Anonymous
in reply to: Anonymous

Thanks sir, but I don't know which topic is relevant to my question. Actually, I could manage to read the objects from the ACA application using these lines of code, but I don't know how to extract object attributes

public void GetObjects()
{
Database db = HostApplicationServices.WorkingDatabase;
Transaction trans = db.TransactionManager.StartTransaction();
RXClass rxc;
BlockTable bt;
BlockTableRecord btr;
bt = (BlockTable)trans.GetObject(db.BlockTableId, OpenMode.ForRead);
btr = (BlockTableRecord)trans.GetObject(bt[BlockTableRecord.ModelSpace], OpenMode.ForRead);

DBObject dbObj;

foreach (ObjectId obID in btr)
{
dbObj = trans.GetObject(obID, OpenMode.ForRead);

rxc= dbObj.GetRXClass();

}


}
Message 4 of 4
Anonymous
in reply to: Anonymous

.NET queries can also be sought at the other location, there was no topic.

--
Dean Saadallah
http://LTisACAD.blogspot.com
--

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

Post to forums  

Autodesk Design & Make Report

”Boost