Im trying to get a selection of certain objects from the modelspace btr of a dwg im opening in code (not in the active autocad window) but failing horribly.
Can anyone point me in the right direction?
Heres a cut down version of code showing where im at until I get to the selection part.
Dim objDB As New Database(False, True) objDB.ReadDwgFile(filePath, FileShare.Read, False, "") Using trans As Transaction = objDB.TransactionManager.StartTransaction Dim bt As BlockTable = trans.GetObject(objDB.BlockTableId, OpenMode.ForRead, False) Dim btr As BlockTableRecord = trans.GetObject(bt(BlockTableRecord.ModelSpace), OpenMode.ForRead)
I've tried a few different things past this point but nothing seems to work. Any advise/code snippets would be appreciated.
Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.