The AutoCAD .NET API
will allow you to create an AutoCAD Database. This can either be a new one or
one that you can populate with a dwg file. The most common workflow however
is to get the currently active database. There are two ways to do this. One
is to use the WorkingDatabase property of HostApplicationServices. The other
is to use the Database property of the MdiActiveDocument as in this c#
snippet. |