;|QQL.LSP - Quik Qleader by Paul Kirill 07/09/02 (pkirill@kdcad.com) ***UPDATED 2/28/05 - fixed little layer setq bug - Added color and linetype to layer creation if required Places leaders and annotation on layer of your choice without taking you away from the current layer. If layer is not present, QQL will create it using your specifications. SPECIAL INSTRUCTIONS: **Change the "MY_DIM_LYR" variable to the layer of your choice **Change the "MY_DIM_CLR" variable to the layer of your choice **Change the "MY_DIM_LTP" variable to the layer of your choice **Type QLL to execute HELPFUL HINTS: **To automatically load this routine each time AutoCAD starts place this file in your AutoCAD path and add (load "") to your ACAD.LSP, ACAD.MNL, or .MNL file. **To automatically load and execute with a toolbar button ^C^C(if (not "")(load ""));; In this case it would read: ^C^C(if (not "QQL")(load "QQL.LSP"));QQL; ***Special thanks to Joe Burke for the TEVAL tip that made this all possible!*** |; (defun C:QQL (/ CLAY TEVAL) (setq MY_DIM_LYR "05-DIMS");;***MODIFY FOR YOUR LAYER (setq MY_DIM_CLR "red") ;;***MODIFY FOR YOUR LAYER COLOR (setq MY_DIM_LTP "continuous");;MODIFY FOR YOUR LAYER LINETYPE (acet-error-init (list (list "cmdecho" 0 "expert" 0) T ) ) (setq TEVAL (getvar "texteval") CLAY (getvar "clayer") ) (setvar "cmdecho" 0) (if (= (tblsearch "layer" MY_DIM_LYR) NIL) (command "-LAYER" "Make" MY_DIM_LYR "C" MY_DIM_CLR MY_DIM_LYR "L" MY_DIM_LTP MY_DIM_LYR "") ) (setvar "clayer" MY_DIM_LYR) (setvar "texteval" 1) (setvar "cmdecho" 1) (command "_qleader") (while (> (getvar "cmdactive") 0) (command pause)) (setvar "cmdecho" 0) (setvar "clayer" CLAY) (setvar "texteval" TEVAL) (setvar "cmdecho" 1) (acet-error-restore) (princ) )