AutoCAD Civil 3D
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic to the Top
- Bookmark
- Subscribe
- Printer Friendly Page
Re: Can not purge blocks
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
We recieved some files from an architect and they contained a bunch of stuff that has been since embeded into our base files. It's making our drawings incredibly slow and frustrating the entire team. We are way too far along to try and re-build new line work. Copying our likework out and wblocking have all resulted in these entities being carried through.
Civil 3D 2013
Re: Can not purge blocks
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
And here's another, safer, variation that will only remove the blocks created by Group:
(vlax-for blk (vla-get-blocks (vla-get-activedocument (vlax-get-acad-object)))
(if (wcmatch (vla-get-name blk) "`*A*")
(vla-delete blk)
)
)
Or another that does the Group blocks and Anonymous blocks:
(vlax-for blk (vla-get-blocks (vla-get-activedocument (vlax-get-acad-object)))
(if (wcmatch (vla-get-name blk) "`*A*,`*U*")
(vla-delete blk)
)
)
Re: Can not purge blocks
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
Here's one that explodes anonymous blocks, something that was driving me nutty:
(defun c:test (/ ss old-echo item ss1 item1)
(setq old-echo (getvar "CMDECHO"))
(setvar "CMDECHO" 0)
(if (setq ss (ssget '((2 . "`*U*"))))
(foreach item (mapcar 'cadr (ssnamex ss))
(command "Explode" item)
(while
(setq ss1 (ssget "_P" '((2 . "`*U*"))))
(foreach item1 (mapcar 'cadr (ssnamex ss1))
(command "Explode" item1)
)
)
)
)
(setq ss nil)
(setq ss1 nil)
(setvar "CMDECHO" old-echo)
(princ)
)Don't know if that is related or not.
Win 7 Pro, 32 bit; Intel Core i5 @ 2.80GHz; 4GB RAM—Civil 3D 2008 & 2011
__________________________________________________________
Credit where credit is due! Give kudos or accept as solution whenever you can.
Re: Can not purge blocks
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
I ended up exporting the linework base file I had to a DXF file and then brought it back in. This allowed me to then purge all of the blocks I was unable to see or purge before. I'm not sure if that's the best way to do it, but nothing else was working. Luckily I didn't have to do something like that to a file that had any built in intelligence, it was just lines. Thanks for everyone's help.
Civil 3D 2013



