Friday, June 14, 2013

Diesel Macro Auto Increment Numbers...

I received a question not too long ago from some one wanting to know how to automate sequential numbering in AutoCAD LT. So, i thought that this would be a good topic to put out there because I am sure that others have wanted to know if this was possible as well.
Anyways...to the topic.

First, the Macro:

*^c^c_text;\;0;$M=$(+,$(getvar,USERR1),$(getvar,USERR2));setvar;USERR1;
$M=$(+,$(getvar,USERR1),$(getvar,USERR2));

One thing that you have to remember is

USERR1 value is going to be your initial value (i.e...99 to start with 100)
Then your USERR2 value is the increment in which you are wanting to increase with each placement of text.
To set these values type userr1 into your command line and hit enter and then enter in the initial value
see pics below:



Once value is set for USERR1, press enter, and then repeat for USERR2.

Now that your starting and incremental value have been set you can run the command and start picking away.

*EDIT*
The above macro justified the text to bottom left; the below macro is modified to justify to middle center.

*^c^c_text;J;MC;\;0;$M=$(+,$(getvar,USERR1),$(getvar,USERR2));setvar;USERR1;



$M=$(+,$(getvar,USERR1),$(getvar,USERR2));

No comments:

Post a Comment