CAD Basics 101 – Drawing Cleanup

Drawing Cleanup is another important aspect of being a good CAD Drafter. Your drawing can start from scratch or from existing drawings. Most of the time it is the latter and we inherit someone else’s mess. This post we will talk about some of the things that can be done to clean your drawing up, before it gets copied across and entire project. How do you clean a drawing? What exactly are we cleaning in our drawing? Our drawing file is essentially a self-contained database. As with any database, it will perform better if it is optimized or free of clutter. Here are just some things that can clutter your drawing.

Empty Text – Text with nothing but spaces.
Empty block references – a hidden block (empty attributes of points)
Nested Block References
Proxy entities or records – Third party custom objects.
Linetypes
Text Styles
Annotation Scales
Wipeouts
Layers
Dimension Styles
Table Styles
Points (Nodes) – use PDMODE and PDSIZE to find these
The List goes on and on…

Here are a few things to consider to help clean up or keep your drawing cleaner.

PURGE COMMAND

PURGE can be used to remove things like Empty text strings from the drawing, Unused layers, block, linetypes, text styles and more. PURGE is pretty much the easiest step to take towards a clean drawing. Keep in mind that you may need to purge a few times because of nesting of objects. If block A has 5 layers defined in it, and you purge block A from the drawing , then it leaves behind the 5 layers. There is an option for purging nested objects, but just know PURGE is a multi-depth process. When PURGE no longer offers anything to purge, then you are done with PURGE.

Tip: If you ever get an older drawing that you think might have empty text strings and want to see just how bad it is, use the QTEXT command and turn QTEXT on. Then REGEN the drawing, zoom extents and see what kind of trash is in the drawing. QTEXT places a box around the contents of text without displaying any fonts. It was used on early releases of AutoCAD to provide faster Regen and redraw times.

SCALELISTEDIT

ANNOTATIVE Scale Factors can be removed from a drawing using SCALELISTEDIT. Why remove scales from the list? SCALELISTS can grow to a massive number of entries, causing more processing on AutoCAD’s part. Every time you reference a drawing or insert a block you have the potential to add more and more entries. There are automated routines out there to help facilitate cleaning these from your drawings. There are a number of tools on the internet to help assist in automatically purging extra scales from your drawings.

 TFRAMES

WIPEOUTS are invisible and often end up driving someone crazy. A less experienced user may open a drawing and plot it. Then notice there is a hole or a portion of something not plotting. They look in the drawing to see and all looks good. They plot again and again. A Wipeout is covering something and can’t be found. The TFRAMES command will allow you to make your WIPEOUTS visible. Review the WIPEOUTS and remove the ones that are not desired. TFRAMES is a Toggle to Toggle a frame to show the wipeout. Sometimes it takes a REGEN to see them, sometimes TFRAMES just doesn’t work. If you find there is no difference, exit AutoCAD and get back in and try again.

How to Find Invisible Blocks

What happens when you have that one block that just won’t go away? This is where you have to do a little detective work. Sometimes it is easy and it is just a hidden block that is nothing more than a block that contains hidden attributes, but nothing you can actually see on the screen. You can use the ATTDISP setting and set Attribute display to ON. ATTDISP set to ON will force hidden attributes to show on the screen, but if the attributes themselves have nothing in them, you still won’t see them. If you set QTEXT to ON and REGEN, then the blank attributes inside the block will show up. Often Third Party software systems will create these for tracking or initializing the drawing. If it is just one and you know it is part of your Software system then leave it, but if you find multiples, you may want to get rid of the extras and let the Third Party software reset itself.

Tip: Another quick way to find out how many times a block is in a drawing, is to use AutoLISP to find them. Start the SELECT command (or any command that you select objects with) and type the following:

(SSGET “X” ‘((0 . “INSERT”)(2 . “BLKNAME”)))[Enter]

Replace BLKNAME with your block name you are looking for. This will add all occurrences of that block to you selection set, note that different space selections will show they were excluded from the selection set. Visit my AutoLISP Teaser Post if you want to play with some more AutoLISP.

Extra blocks

Some other issues that can cause problems is when a user uses the Clipboard copy methods and paste as block. This creates an auto generated blockname that typically looks like A$7EDF1341A. You can easily end up with lots of these blocks that may just be nested blocks. Often times the user may just wish to copy a block from one drawing to another, so they think, copy as block. Unfortunately that is not exactly what happens when selecting copy as block. What happens with that approach is AutoCAD creates a nested block that contains the block you selected and creates a new auto generated block name for your new block. To do this operation properly, simply select a block in Drawing A (it is already a block) simply Ctl-Shift+C (Copy with basepoint); select the insertion point of the block. If INS osnap does not show, then it is probably not a block. Then select the block and press enter. Open up the destination drawing (Drawing B) and simply use Ctl+V (Paste) pick your insertion point and you are done. The only block definition is the one you wanted. If you find lots of Auto generated Block Names in your drawing you will want to check their block definition and if they are just nested blocks, explode them to un-nest them. Then you can purge the Auto generated block. If the block is comprised of entities and such that are desired to be a block, then use the RENAME command to rename the block to an appropriate name.

PROXY Entities – Hate em’

Proxy objects are essentially custom objects (graphical and non-graphical) that were defined and created by a Third party application that is not currently loaded into AutoCAD. Keep in mind that could be an AutoDesk AutoCAD-addon application too. Custom Objects come from Applications like CADWorx or AutoCAD Civil or… To get rid of the proxy you will want to load the correct object enabler for the object. When you see the dialog box stating proxies, you will also see what application it is looking for in the list, so don’t just dismiss it. Review it and find the correct enabler. If you do not want the proxies in your drawing but you want the graphics they represent, you will need to use the enabler’s exporttocad ability. Each enabler does not necessarily provide this functionality. You will need to research it and find out the correct command name to do so. I’ll probably write a post on this later. Once you rid your drawing of them, then you should be in pretty good shape for that drawing. Proxy objects prevent things like Wblock, or Binding Xrefs and can easily propagate into other drawings if you don’t take care of them.

What else?

There are a number of other things, Microstation linetype issues, Annonomous groups, and more that can get in to your drawing and make it a nightmare to just pass on and inherit to multitudes of other drawings, so always start with a fresh drawing and copy just what you want from existing drawings. Save it and check the drawing size. If it gets large quick, you may have copied in something corrupt. Work through what you copied and try and isolate what or where the corruption is. Since things like Drawing Templates or Title Blocks are used throughout projects it is VERY IMPORTANT to make sure these drawings are CLEAN.

AutoCAD Drawing files have become very complex with all the new features that AutoDesk keeps adding into AutoCAD. I did not cover everything here, but I tried to cover some of the most common things. Do your best to avoid passing on corruption or trash in your drawings. This will improve quality and keep your system operating more efficiently.

Leave a Reply