Drawing structure
-
Firstly I should apologise to those readers using RSS to access this site: I've been playing around with the configuration, to integrate FeedBurner but also to switch from publishing entire articles via RSS to publishing introductions - my posts are just too long, which seems to cause a problem for some RSS readers. So you […]
-
This post continues on from the last one, which introduced some code that creates "Koch curves" inside AutoCAD. Not in itself something you'll want to do to your drawings, but the techniques shown may well prove helpful for your applications. Last time we implemented support for Lines and Arcs - in this post we extend […]
-
I'm currently waiting to get my RealDWG license through, so I'll interrupt the previous series on side databases to focus on something a little different. I'll get back to it, in due course, I promise. 🙂 A long time ago, back during my first few years at Autodesk (which logically must have been some time […]
-
I was inspired by some code sent out by Viru Aithal to write a command that iterates through the vertices of the various types of AutoCAD polyline: Optimized (or "lightweight") 2D polylines, which store an array of 2D vertices Old-format (or "heavyweight") 2D polylines, which contain a sequence of 2D vertex objects 3D polylines, which […]
-
A follow-up question came in related to the last post, around how to add XData to entities using .NET. Extended Entity Data (XData) is a legacy mechanism to attach additional information to AutoCAD entities. I say "legacy" as there are limits inherent to using XData, which make other mechanisms more appropriate when storing significant amounts […]
-
This comment came in overnight from Brian: I was hoping to work out how to get the Entity from the handle and then erase it, from your posts, I've learned a lot but not found the answer to this one yet, I still have a mountain to climb. (I'm using VB.NET, I've done it in […]
-
Someone asked me earlier today how to iteratively change the color of entities inside blocks. The following code uses a recursive helper function to iterate down through the contents of a block, changing the various entities (other than block references, for which we simply recurse) to a specified colour. Here's the C# code: using Autodesk.AutoCAD.ApplicationServices; […]
-
In the previous post we looked at some code that created chains of circles, linking them together using .NET events (a technique that can be used to maintain other types of geometric relationship, of course). In this post, we're going to extend our sample to support persistence of the link data in the AutoCAD database. […]