VBA for AutoCAD®

AutoCAD®, VB and Mathematics

by Will on May 20, 2011

If you want to become an expert AutoCAD® script writer, at some point you’re going to need to know a bit about maths, or at least have the capacity to learn. It doesn’t have to calculus, but stuff like Pythagoras ..read more


random shape

I’ve had a few requests recently to do a post on creating executables that control AutoCAD®. Though generally it is better to have tools well integrated into AutoCAD® via the use of a NETLOADed dll for example, sometimes an exe ..read more


Screenshot Of Points

Today I’m going to show you how to use a bit of simple VBA to export data to a CSV file. It’s really simple, and although there are other ways of achieving the same thing, this way allows great flexibility, ..read more


One of my readers has requested some help regarding the drawing of windows. I’m not 100% sure of his exact requirements, but it’s a good opportunity for me to build on what I’ve already shown you. This will be a ..read more


Longest Path

Been struggling to find time to post on here recently due to exams, work and planning a wedding… with a bit of a lull in between everything, now’s a good time to get back in the swing of it!

Join The ..read more


VB.NET AutoCAD® Template

by Will on February 18, 2011

For those interested in AutoCAD® development, there are a few files that need to be referenced so that you can work with AutoCAD®. So, ideally, you’ll want to set up a basic template that you can use with all the ..read more


Many people are oblivious to the wondrous things that can be achieved with programming. If you cringe at the prospect of writing code, I’ll put this to you now – I cringe at the thought of having to do things ..read more


Here’s a simple example of some VBA code that might come in handy either as a learning exercise, or if you happen to be trying to break a line programatically.

The code fistly asks the user to select a line, and ..read more



by Will on December 7, 2010

If you’ve ever tried to edit the widthfactor of mtext through VBA or VB.NET, you’ll have realised that there isn’t a method for doing so. However, there is a built in trick which bypasses the requirement for doing this. Try ..read more



by Will on December 6, 2010

ThisDrawing.PaperSpace is a very useful way to access the PaperSpace of your drawing through VBA or VB.NET.

When developing tools that draw entites in a drawing, we can sometimes use ThisDrawing.PaperSpace, forgetting that the tool might actually end up being used ..read more