Lazy System Variable: ATTDIA

There may be times when you would want to turn on/off the dialog box when inserting an attributed block into your drawings. For example, if you are creating a script or macro that inserts an attributed block you might want to set ATTDIA to 0 (zero) at the beginning so that the it will prompt for attributes on the command line only.

Take my previous post on writing AutoCAD scripts with Excel for example. If you had a block that had Northing, Easting, & Elevation attributes in it, you could copy/paste the Northing, Easting, & Elevation cells where they need to be after the block insertion (in the correct order of course) so that when the insertion command prompts for the attributes, they are filled with the data provided in the Excel spreadsheet.

CAUTION: When filling in attribute data with a script, it accepts spaces. This means that the value/data filling in each attribute needs to be on it’s own line inside the script file.

Of course, to make sure it runs on command line only, you should add this to the beginning of your script:

ATTDIA 0

Play with it.

2 Comments so far

  1. CadKicks.com on November 18th, 2008

    Lazy System Variable: ATTDIA…

    You’ve been kicked (a good thing) – Trackback from CadKicks.com…

  2. kellydehn on January 27th, 2009

    So, this meansATTDIA 0-INSERT PNT 5000,5000,500 1  0 P1 TREE will not work? It has to be? (P1 and TREE being the attributes with in the block)-INSERT PNT 5000,5000,500 1  0 P1TREE ATTDIA 1It would be nice if you could keep everything on a single line.

Leave a reply