Delete AutoCAD layer filters
Often requested tool. Here it is again. I just confirmed that it works great in AutoCAD 2006 as well.
;;; DLF.LSP ;;; ;;; Delete all layer filters with the DLF command ;;; ;;; By Jimmy Bergmark ;;; Copyright (C) 2004-2006 JTB World, All Rights Reserved ;;; Website: www.jtbworld.com ;;; E-mail: info@jtbworld.com ;;; 2004-05-23 - Added support to delete filters introduced in 2005 ;;; 2005-03-14 - Confirmed to work with AutoCAD 2006 ;;; 2005-04-19 - Added (vl-load-com) ;;; Written for AutoCAD 2000, 2000i, 2002, 2004, 2005, 2006, 2007 ;;; (vl-load-com) ;;; Purge/delete all layer filter or filters ;;; Example: (DeleteLayerFilters) (defun DeleteLayerFilters () (vl-Catch-All-Apply '(lambda () (vla-Remove (vla-GetExtensionDictionary (vla-Get-Layers (vla-Get-ActiveDocument (vlax-Get-Acad-Object)))) "ACAD_LAYERFILTERS"))) ) ;;; Purge/delete all layer filter or filters compatible with 2005 or later ;;; Example: (DeleteLayerFilters2) (defun DeleteLayerFilters2 () (vl-Catch-All-Apply '(lambda () (vla-Remove (vla-GetExtensionDictionary (vla-Get-Layers (vla-Get-ActiveDocument (vlax-Get-Acad-Object)))) "AcLyDictionary"))) ) (defun c:dlf() (DeleteLayerFilters) (DeleteLayerFilters2) (princ "\nAll layer filters deleted!") (princ) )To batch purge multiple drawings automatically take a look at SmartPurger.



20 comments (add your comment):
Thank you !!!!!!!
FANTASTIC mate!!
This has saved me so much time!
Our clients drawings used to take nearly 4 minutes to display the layer command - and I used to forget why I wanted the Layers displayed after the wait ....
Thank you VERY much!
This is the only one that works among all those lisp files on internet. Thank you so much.
(defun merit()
(princ "Excelent")
(princ "THANK YOU JIMMY")
(princ)
)
Hey... This sounds great to me but I am not sure how to load the application. Can you tell me step by step please? Thank you.
Appreciate it..!!
Hey.. it sounds great. I really need this cause the layers are getting to me..!!!
But I am not sure how to load it. Can you please show me step by step??
THank you.. Appreciate it..!!
To load the application use the command APPLOAD then you can add the DLF.LSP file to the startup suite. Or you can drag and drop the DLF.LSP file into AutoCAD. Then you can use the DLF command.
hey.. thanks for replying so quickly. I am using CAD LT2002. And when I load the applicatoin and typed dlf、nothing happened.
Thanks for being patient//!
Sorry, but AutoCAD LT does not support AutoLISP.
DAMN..!!
I thought I found a magic potion..!! hmm do u know any other suggestion??
Unfortunately none other than upgrade to a later version of LT or full AutoCAD. I think some later versions of LT supports to delete layer filters when you open a drawing. If you manually want to delete layer filters on a drawing you can maybe do that from the layer dialog box. It might be possible to select all using CTRL or SHIFT.
I can delete them but it takes time because its populated with them and I have to delete them 1 by 1 that is the problem.
Well let me know if you know an easier way.
Thanks
OMG.
Just loaded the lisp file and a second later they are gone. copied the lisp to the support directory, used appload to load it and then typed dlf. filters gone.
Thanks from all of us.
Thank you, you saved me a lot of time and my sanity
for real speed, try the purgeids prog from cadthinking.com, it does app id's and layer filters both. It is literally 100 times faster than scripting through drawings and is the only practical way to purge registered app id's.
Thank you soooooo much. Now I can make my dead line. It was so quick and simple that I wish I asked for help 2 days ago.
Thank you Jimmy a million times over.
Thanks a lot!
It works on AutoCAD 2008!
It does not seam to work in AutoCAD 2004. Any Ideas Jimmy?
Never Mind. It works great. Just had to save and reopen the file.
thanks
Peter, good to hear you found out how to do it.
Post a Comment |
Subscribe to the comments feed