Thom Beauchamp e-mailed a request to take a set of 10 or so drawings, each with 2,200 or more attributed blocks, and purge all of the attributes, leaving the graphics for the blocks intact. The AutoLISP Solution is PURGE-ATTRIBS.LSP and its dialog-box control counterpart PURGE-ATTRIBS.DCL. The purge routine automatically removes every attribute from every block reference. The only user interaction is to select the drawings to be purged from a dialog box list.
HOW TO USE PURGE-ATTRIBS.LSP
Download the LSP and the DCL files from our Get the Code section and save them in the AutoCAD support directory. From the AutoCAD tools menu, choose Load Applications, or enter Appload at the AutoCAD command prompt. In the Load/Unload Applications dialog box, select the PURGE-ATTRIBS.LSP file from the support directory where you installed it, then click Close. After you load the program, AutoCAD prompts you to enter PA to start.
When the program starts, you see the dialog box shown in figure 1.
A note on the dialog box reads:
Note: Single Document Interface only.
You must set system variables SDI = 1,
and LISPINIT = 0 If these are not set,
press the Cancel button and set them.
|