AutoCAD-101
Basic AutoCAD plugin using C# .NET
dll references:
- C:\Program Files\Autodesk\AutoCAD 2018\accoremgd.dll
- C:\Program Files\Autodesk\AutoCAD 2018\acdbmgd.dll
- C:\Program Files\Autodesk\AutoCAD 2018\acmgd.dll
- System.Windows.Forms
Steps to Run the Code:
- Open the project (.csproj) in Visual Studio
- Click "Build Solution" under Build menu in ribbon (Ctrl+Shift+B)
- "bin\debug" folder will be create under you root directory
- Make sure that the "bin\debug" folder contains a ".dll" file with the name of your project.
- Open AutoCAD and create a new blank drawing
- Type in "NETLOAD" command which lets you load the plugin you build above in step 4
- Choose the ".dll" file from the "bin\debug" folder
- Hit Open - the plugin will be loaded
Test the Plugin:
- Draw a Rectange of any dimension
- Type "SelectObjectsOnScreen" command in AutoCAD and hit enter
- Choose the Rectange that you drew in step 1 & hit enter
- The Bounds of the rectangle will be displayed in a pop-up.