Reversing layers

liv4gzus

Usenet Archive
Joined
Jan 26, 2004
Messages
2
Reaction score
0
I am looking to find out if there is a single command that will reverse all layers at once. For example, if I have 5 layers in a drawing and 3 are frozen and 2 are thawed, is there a single command that will reverse these layers so that there would now be 2 frozen and 3 thawed? I know if I only have a small amount of layers reversing them by simply picking them is fine, but if you have 100 it gets to be a little tedious. Thanks for the help.
 
See my response to this question in the 2002general newsgroup.

Jeff

liv4gzus said:
I am looking to find out if there is a single command that will reverse
all layers at once. For example, if I have 5 layers in a drawing and 3 are frozen and 2 are thawed, is there a single command that will reverse these layers so that there would now be 2 frozen and 3 thawed? I know if I only have a small amount of layers reversing them by simply picking them is fine, but if you have 100 it gets to be a little tedious. Thanks for the help.
 
Jeff,

I saw your response. Could you please send me that lsp at . I would appreciate it. Thanks.
 
Here is a Lisp:
Give it a whirl.

(defun C:RL ; reverse Layers..
;; note: Only Freeze / Thaw, does not 'lock' or set 'plot' bits. (setq laylist nil) (setq lt (tblnext "LAYER" T)); reset to top of Table (while (setq lt (tblnext "LAYER")) (setq ln (cdr lt)) (setq lx (cdr (assoc 2 ln))) (if (/= lx "0") (progn (setq x (cdr (assoc 70 ln))); get visible bit (if (= x 0) (command "_layer" "_on" lx "_f" lx "") ); end if (if (= x 1) (command "_layer" "_on" lx "_t" lx "") ); end if ); end progn ); end if ); end while (princ)
); end function

Bob Shaw
(bobscadshop.com)
 

Latest threads

Back
Top