Transcription of AutoCAD .NET Developer's Guide - Autodesk
1 AutoCAD .NET Developer s GuideStephen PretonAutodesk Developer Technical Services Team (DevTech) AutoCAD .NET Developers GuideAuthor:Stephen PretonAutodesk Developer Technical Services Team (DevTech)Contents1 in this of the AutoCAD .NET of the AutoCAD .NET of Microsoft Visual in this Edition of Microsoft Visual Studio to COM Interoperability with . and 27 For More from ActiveX Automation to . Getting Started with Microsoft Visual in this Microsoft Visual Studio the Components in a Project with Microsoft Visual Studio in this a New an Existing Project or a Project or with Multiple Projects in a a project to a 37 Unload a project from a an Existing Project or in this New Existing in this the Code the Windows Form the Properties a and Reference Other Projects .. the Options for Microsoft Visual an Assembly into and Search Referenced Libraries (Object Browser).. : Create Your First in this : Create a New 50 Exercise: Reference the AutoCAD .
2 NET API : Create a New : Set the Target Framework for a : Build and Load a .NET Assembly in AutoCAD Commands and Basics of the AutoCAD .NET in this the AutoCAD Object in this Application Document Database Tables and Cross Graphical and Nongraphical Collection Graphical and Nongraphical the Object #..65 Topics in this Objects in the Object #.. #.. #.. #..67 VBA/ActiveX Code the Application #..68 VBA/ActiveX Code in this a #..70 VBA/ActiveX Code a New Member to a Collection #..71 VBA/ActiveX Code through a Collection #..73 VBA/ActiveX Code through the LayerTable #..73 VBA/ActiveX Code the layer table record named MyLayer in the LayerTable #..75 VBA/ActiveX Code a Member of a Collection #..76 VBA/ActiveX Code Properties and -Process versus #..80 VBA/ActiveX Code Commands and AutoLISP in this to Define a #.. #..83 AutoLISP Function to Define an AutoLISP #..84 Retrieve Values Passed into an AutoLISP define an AutoLISP #.
3 854 Control the AutoCAD in this the Application and size the Application #..87 VBA/ActiveX Code and maximize the Application #.. #..88 VBA/ActiveX Code the Application window invisible and #..89 VBA/ActiveX Code the Drawing in this and Size the Document the active Document #..91 VBA/ActiveX Code and maximize the active Document #..92 VBA/ActiveX Code the current state of the active Document #..92 VBA/ActiveX Code and Pan the Current in this the Current 93 VBA Code Cross used to manipulate the current #..96 Define to to an area defined by two #..99 VBA/ActiveX Code a in on the active drawing using a specified #..101 VBA/ActiveX Code #..102 VBA/ActiveX Code Drawing Extents and the extents of the current the limits of the current in to the extents and limits of the current #..103 VBA/ActiveX Code Named Views ..104 Add a named view and set it #..105 VBA/ActiveX Code a named #..107 VBA/ActiveX Code Tiled in this and Manipulate the Active a new tiled viewport configuration with two horizontal #.
4 111 VBA/ActiveX Code A Tiled Viewport a viewport, then iterate through the #..114 VBA/ActiveX Code the Geometry in the Document #..117 VBA/ActiveX Code , Open, Save, and Close Code in this and Open a a new #..118 VBA/ActiveX Code an existing #..119 VBA/ActiveX Code and Close a a the active #..121 VBA/ActiveX Code if a drawing has unsaved #..122 VBA/ActiveX Code with No Documents the application #..124 Lock and Unlock a a database before modifying an #..127 Set AutoCAD the Preferences #..128 VBA/ActiveX Code the crosshairs to full #..129 VBA/ActiveX Code the screen menu and scroll #..130 VBA/ActiveX Code in this and Return System #..131 VBA/ActiveX Code with in this Snap and Grid the grid and snap #..133 VBA/ActiveX Code Ortho #..135 VBA/ActiveX Code Points and angle from #..136 VBA/ActiveX Code Polar #..137 VBA/ActiveX Code the distance between two points with the GetDistance #..139 VBA/ActiveX Code in this a Defined the area defined by points entered from the #.
5 141 VBA/ActiveX Code for User in this a string value from the user at the AutoCAD command #..144 VBA/ActiveX Code a point selected by the #..146 VBA/ActiveX Code a keyword from the user at the AutoCAD command #..148 VBA/ActiveX Code #..149 VBA/ActiveX Code User an integer value or a #..151 VBA/ActiveX Code the AutoCAD Command a command to the AutoCAD command #..153 VBA/ActiveX Code Create and Edit AutoCAD in this and Close in this with an Object an #..156 Use Transactions with the Transaction in this a New Transaction and Open an #..158 Add a new object to the #..159 Commit and Rollback #..160 Nest nested transactions to create and modify #..163 Open and Close Objects without the Transaction #..166 Add a new object to the #..168 Upgrade and Downgrade Open #..170 Create in this the Parent Model space, Paper space or the current #..173 VBA/ActiveX Code in this a Line #..176 VBA/ActiveX Code a Polyline #.
6 178 VBA/ActiveX Code in this a Circle #..180 VBA/ActiveX Code an Arc #..182 VBA/ActiveX Code a Spline #..184 VBA/ActiveX Code Point a Point object and change its #..187 VBA/ActiveX Code Solid-Filled #..189 VBA/ActiveX Code with in this a simple #..192 VBA/ActiveX Code Composite 194 Subtract the intersection of two a composite #..195 VBA/ActiveX Code in this a Hatch a the Hatch Pattern Type and the Hatch a Hatch #..201 VBA/ActiveX Code with Selection in this the PickFirst Selection the Pickfirst selection #..204 VBA/ActiveX Code Objects in the Drawing for objects on screen and iterate the selection #..207 VBA/ActiveX Code Reference .. #..209 VBA/ActiveX Code To or Merge Multiple Selection selected objects to a selection #..211 VBA/ActiveX Code Rules for Selection in this Selection Filters to Define Selection Set a single selection criterion for a selection #..214 VBA/ActiveX Code Multiple Criteria in a Selection objects that meet two #.
7 216 VBA/ActiveX Code Complexity to Your Filter List a circle whose radius is greater than or equal to #..219 VBA/ActiveX Code either Text or #..220 VBA/ActiveX Code Wild-Card Patterns in Selection Set Filter MText where a specific word appears in the #..223 VBA/ActiveX Code for Extended circles that contain #..224 VBA/ActiveX Code Objects From a Selection Named and 2D in this with Named in this Unreferenced Named all unreferenced #..229 Rename a #..231 Erase and erase a #..232 VBA/ActiveX Code in this an a single #..235 VBA/ActiveX Code multiple #..237 VBA/ActiveX Code Objects between an object from one database to #..241 VBA/ActiveX Code a #..245 VBA/ActiveX Code #..247 Example of a rotation #..248 Additional examples of transformation in this a circle along a #..251 VBA/ActiveX Code a polyline about a base #..253 VBA/ActiveX Code a polyline about an #..256 VBA/ActiveX Code a #..260 VBA/ActiveX Code in this Polar #.
8 264 VBA/ActiveX Code Rectangular #..268 VBA/ActiveX Code and Trim a #..272 VBA/ActiveX Code a #..275 VBA/ActiveX Code a #..278 VBA/ActiveX Code in this Hatch an inner loop to a #..282 VBA/ActiveX Code Hatch the pattern spacing of a #..286 VBA/ActiveX Code Layers, Colors, and in this with in this Layers and through the Layers #..290 VBA/ActiveX Code and Name a new layer, assign it the color red, and add an object to the #..292 VBA/ActiveX Code a Layer a layer current through the #..295 VBA/ActiveX Code Code Layers On and off a #..297 VBA/ActiveX Code and Thaw a #..300 VBA/ActiveX Code and Unlock a #..302 VBA/ActiveX Code Color to a the color of a #..305 VBA/ActiveX Code a Linetype to a the linetype for a #..308 VBA/ActiveX Code #..310 VBA/ActiveX Code with in this a color value to an #..313 VBA/ActiveX Code a color current through the #..315 Make a color current with the CECOLOR system #.
9 315 VBA/ActiveX Code with a linetype into #..316 VBA/ActiveX Code in this a Linetype in this a linetype to an #..319 VBA/ActiveX Code a linetype current through the #..321 VBA/ActiveX Code Reference ..322 Make a linetype current with the CELTYPE system #..322 VBA/ActiveX Code Linetype the description of a #..323 VBA/ActiveX Code Linetype the linetype scale for an #..326 VBA/ActiveX Code and Restore Layer in this How AutoCAD Saves Layer the saved layer states in a #..329 VBA/ActiveX Code the LayerStateManager to Manage Layer #..331 VBA/ActiveX Code in this Layer a layer's color and linetype #..333 VBA/ActiveX Code Layer Imports 334C#..334 VBA/ActiveX Code Layer #..335 VBA/ActiveX Code Layer the color and linetype settings of a drawing's #..337 VBA/ActiveX Code and Import Saved Layer saved layer #..339 VBA/ActiveX Code saved layer #..340 VBA/ActiveX Code Text to in this with Text in this and Modify Text text #.
10 344 VBA/ActiveX Code TrueType Unicode and Big 345 Change font #..346 VBA/ActiveX Code Text Obliquing oblique #..348 VBA/ActiveX Code Text Generation text #..350 VBA/ActiveX Code Single-Line Text (Text)..352 Topics in this Single-Line Create Line #..353 VBA/ActiveX Code Single-Line Single-Line #..357 VBA/ActiveX Code Single-Line Multiline Text (MText)..359 Topics in this Multiline a multiline text #..361 VBA/ActiveX Code Multiline control characters to format #..363 VBA/ActiveX Code Unicode Characters, Control Codes, and Special an Alternative Default Dimensions and in this in this of a the Dimension System #..370 VBA/ActiveX Code Dimension Text Leader Associative in this Linear #..373 VBA/ActiveX Code a rotated linear #..375 VBA/ActiveX Code Radial a radial #..377 VBA/ActiveX Code Angular an angular #..380 VBA/ActiveX Code Jogged Radius a jogged radius #..383 VBA/ActiveX Code Arc Length an arc length #.