seashell2day Posted March 31, 2009 Share Posted March 31, 2009 How do i delete layers in autocad 2009 when the sign comes up that the layers are being used when they are clearly not. How can i find out what is holding onto my layer & stopping it from going? I use quick select to select everything on the layer i want to delete. It selects nothing because there is nothing on the layer i want to delete. It's not the current layer, not the 0 layer & it's not used by any xref. how do i delete it? Quote Link to comment Share on other sites More sharing options...
CarlB Posted March 31, 2009 Share Posted March 31, 2009 Could be that a block attribute is on that layer. Does 2009 have the Express Tools "laydel" command? Draw an object on the layer to be deleted, run "laydel", select that object...or so I heard explained better at this site recently. Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted March 31, 2009 Share Posted March 31, 2009 Could be that a block attribute is on that layer. Does 2009 have the Express Tools "laydel" command? Draw an object on the layer to be deleted, run "laydel", select that object...or so I heard explained better at this site recently. Not sure if laydel is actually mainstream now on '09 - I heard that laymrg is mainstream, so maybe laydel is also. Quote Link to comment Share on other sites More sharing options...
ReMark Posted March 31, 2009 Share Posted March 31, 2009 AutoCAD 2009: Menu Browser > Format > Layer Tools > Layer Delete. If all else fails you can WBlock out everything you can see in the drawing then start a new drawing and insert what you have. Check to see if the problem layers still exist. Quote Link to comment Share on other sites More sharing options...
MiGo Posted March 31, 2009 Share Posted March 31, 2009 For MEP 2008 the Laydel is a fully functional command, so my guess is it should be in Acad 2009. Just draw a line on the layer you want to delete type in "laydel" and select the line, or you can just type in "laydel" and hit "n" for name and a dialog box should pop up with all the current layers. Just select the one you want gone and it will delete the layer and all of the contents on that layer. Quote Link to comment Share on other sites More sharing options...
Lee Mac Posted March 31, 2009 Share Posted March 31, 2009 You can use this to check block entities on layers: ; Get All on Layer by Lee McDonnell ; Args:- layer (string) (defun get_all_on_layer (layer / ss eLst blks att aBlst ents eBlst) (if (tblsearch "LAYER" layer) (progn (setq eBlst (strcat "Entities within Blocks on Layer " layer ": \n\n")) (foreach x (blk_list) (setq ents (entnext (tblobjname "BLOCK" x))) (while ents (if (eq layer (cdr (assoc 8 (entget ents)))) (setq eBlst (strcat eBlst (cdr (assoc 0 (entget ents))) " Within Block: " x "\n"))) (setq ents (entnext ents)))) (alert eBlst)) (princ "\n<!> Layer Not Found in Drawing <!>")) (princ)) (defun blk_list (/ bLst) (vlax-for blk (vla-get-blocks (vla-get-activedocument (vlax-get-acad-object))) (setq bLst (cons (vla-get-name blk) bLst))) (setq bLst (vl-remove-if (function (lambda (x) (or (wcmatch x "*PAPER*") (wcmatch x "*MODEL*")))) bLst)) bLst) (defun c:test () (get_all_on_layer (getstring "\nSpecify Layer: ")) (princ)) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.