Community
AutoCAD LT Forum
Welcome to Autodesk’s AutoCAD LT Forums. Share your knowledge, ask questions, and explore popular AutoCAD LT topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Cleaning Up files using DXF + Recover

11 REPLIES 11
SOLVED
Reply
Message 1 of 12
mdwyerva
5479 Views, 11 Replies

Cleaning Up files using DXF + Recover

Using LT 2012, I noticed some of our files were getting unsually large (for us).   We also had some mystery line types and layers.  Then some of the files started to crash when saved and freeze up when audited which was the last straw.  These are mechanical and electrical plans for buildings, and not particulary big plans or buildings.    I have used LT for 20 years or more, so maybe old blocks or whatever.   We are forced to use many files from architects and owners and god knows where these files grew up and how they became became cranky.  

 

I came up with a clean-up routine listed below.  Using this method, a 10 mb file becomes 100Kb (approx) without any loss of functionality for me - am I missing something?   I have not noticed any issues,but only used for a week or so.

I can get some benefits doing only some of these steps.   Like all clean-ups, I am not sure the benefits last if I re-pollute the file somehow, but do any of these steps cause future problems?

 

  1. Open file.dwg
  2. saveas 2004 dxf file (not dwg, dxf)
  3. close file and type new <Enter>
  4. type dxfin and select your file (xrefs will be 'missing'  - ignore this issue, they come back at the end) 
  5. audit (may takes a few minutes), and say Y to fix errors.
  6. purge all 
  7. -purge R (for Regapps), * for all and then No 
  8. saveas file.dwg (2010 dwg)
  9. close
  10. recover file.dwg
  11. purge all
  12. -purge R
  13. save

if it won't saveas DXF, then do this first:

  • Open file
  • -PUrge Regapps, *, n (deleted 78,000+ apps on p41)
  • save
  • close
  • Recover file, and once it is open, follow steps below.

 

Matt Dwyer

 

Tags (3)
11 REPLIES 11
Message 2 of 12
Charles_Shade
in reply to: mdwyerva

Depending on the age of the Blocks and other drawing files and the CAD vesion they were created these files could be infected with Scalelist and Layer filter issues.

Likely what you are doing is removing a piece of this bad information and thus the size of the drawings is less.

WBLOCK may be of some help. Did you try this?

 

This is a Macro that was developed from a question over at the AUGI Forum:

^C^C._-purge;_all;*;_no;._-purge;_regapps;*;_no;._zoom;_extents;._-layer;_set;0;;._audit;yes;._-overkill;all;;done;

(some of the info is just for my use but the basics of the Macro there.)

This does a lot of what you described and may be helpful as well.

 

Thanks for sharing the routine you came up with.

Message 3 of 12
mdwyerva
in reply to: mdwyerva

I have used wblock in the past, but did not try it here.  I did notice that recover (can't even audit some of these, must use recover) and purge failed to clean some of these files.   I fell back on dxf, because historically it was a useful trick, although adds clutter to directory if you don't erase the dxf later.    I forgot overkill, so thanks for that.  Scripts are certainly nicer than routines where you keep stopping to select or type filenames.  

Message 4 of 12
Charles_Shade
in reply to: mdwyerva

Traveling back to Release 12 can be useful as well.

 

Took me several tries to get Overkill set to where it did not muck with the drawing. I've got so many options turned Off that I am not sure that when I use it it does anything. Smiley Very Happy

Message 5 of 12
pendean
in reply to: mdwyerva

RECOVER, then WBLOCK followed by -EXPORTTOAUTOCAD command's R2007 or R2004 or R2000 or R14 options on the newly create file (depends on the AEC content in the files) has been the better approach except for exceptionally difficult files in which only and R12DXF export will fix.

 

Resorting to DXF first is often needless step for most users IMHO.

Message 6 of 12
mdwyerva
in reply to: pendean

Thanks, Dean.   Good to know. 

Message 7 of 12
mdwyerva
in reply to: pendean

I think what I did not understand till just now is that you can select ENTIRE DRAWING with wblock command.   This avoids having to fuss with turning on all layers and worrying that you have pulled in the xrefs, etc (which would be error-prone for me), yes?  Someday I will actually read all the dialog boxes... 

 

I just tested a couple times and just doing WBLOCK did 90% to 100% of the work in a second  (as opposed to minutes and multiple dialog boxes).    

Message 8 of 12
Charles_Shade
in reply to: mdwyerva

I think you learned how to fish!

Message 9 of 12
mdwyerva
in reply to: Charles_Shade

Amen.

 

Follow up question tho -  let's say I have two files (A1 and A2) that are pigs (~7MB for no good reason) and I use wblock ENTIRE DRAWING to reduce one (A1) to 0.3 MB.    Then, I insert a 6" circle (not a block, not group, a circle) from the other pig file (A2) into the newly svelte drawing A1.   All of sudden, A1 is nearly as fat as it was (pops up to 4MB or so) thanks to inserting a simple circle from A2.  

 

Is there something ELSE I am missing here?  This seems to happen regardless of what I chose to insert (circle, line, text, whatever).  If I clean BOTH files (using wblock/entire) then this does NOT happen.   So, I know what to do in theory, but it is puzzling.   Esp, since it occurs when I wblock and then insert.  🙂   

 

I apologize if there is a good thread that explains all this, I probably should do more research.  

Message 10 of 12
Charles_Shade
in reply to: mdwyerva

Does using Insert this way grab bad info (i.e. Scalelists, Layer filters) from A2?

Message 11 of 12
mdwyerva
in reply to: Charles_Shade

The circle file is 3MB because of all the linestyles and textstyles that it mysteriously (to me) drags along with it.  These are all from the underlying architectural xrefs (which were not selected!).   It is pretty bizarre, since if you do a LIST ALL on this 3 MB file, you get exactly one object.


Command: list

Select objects: all
1 found

Select objects:

CIRCLE Layer: "de-mducts"
Space: Model space
Handle = a8
center point, X=950'-8 27/32" Y=54'-9 17/32" Z= 0'-0"
radius 0'-3"
circumference 1'-6 27/32"
area 28.27 sq in (0.1963 sq ft)

 

The only way I found what was in it was to do a PURGE and look at items that can not be purged (there were NO items that could be purged).    

 

Not sure why wblock ENTIRE would perfectly clean a big pig drawing, and why wblock SELECT would include a 10 ton pile of crap in with a simple object.  

Message 12 of 12
mdwyerva
in reply to: mdwyerva

and for any lurkers... I find that people need to be set to save in 2010 dwg format to see max reduction.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost