xspacex Posted October 28, 2009 Posted October 28, 2009 Hello everyone, I am in need of some help with this lisp that I am putting together. The code below will basically thaw a specific frozen layer, however, it will not automatically regen after the thaw - the reason for the regen, is so that all objects, lines... that were frozen on this specific layer, will now appear - while I tried the command regen in the lisp, it did not work, so I am looking for suggestions? Using the same method below, I am wondering how to thaw a layer frozen in a viewport? Cheers! (if (setq ename (tblobjname "layer" layname)) (progn (setq layent (entget ename)) (if (= (cdr (assoc 70 layent)) 1) (progn (setq layent (subst (cons 70 0) (assoc 70 layent) layent)) (entmod layent) (entupd(cdr (assoc -1 layent))) ) ) ) ) Quote
David Bethel Posted October 28, 2009 Posted October 28, 2009 How about (command "REGENALL") -David Quote
xspacex Posted October 28, 2009 Author Posted October 28, 2009 is there a way to thaw a viewport layer using assoc 70, and using subst (cons...? Quote
David Bethel Posted October 29, 2009 Posted October 29, 2009 is there a way to thaw a viewport layer using assoc 70, and using subst (cons...? Not that I know of. VPlayer data is stored as xdata in the VIEWPORT entity and you cannot entmod a VIEWPORT. -David Quote
xspacex Posted October 29, 2009 Author Posted October 29, 2009 Since I cannot entmod a vplayer, I tried something like this, but it didn't work?? Any suggestions... Thanks again (if (setq ename (tblobjname "layer" layname)) (progn (setq layent (entget ename)) (if (and (= (getvar "tilemode") 0)(/= (getvar "cvport") 1)) (progn (command "vplayer" "thaw" layent "" "") ) (princ) ) ) ) Quote
lpseifert Posted October 29, 2009 Posted October 29, 2009 maybe this will work for you (command "vplayer" "thaw" (cdr (assoc 2 layent)) "" "") Quote
alanjt Posted October 29, 2009 Posted October 29, 2009 Since I cannot entmod a vplayer, I tried something like this, but it didn't work?? Any suggestions... Thanks again (if (setq ename (tblobjname "layer" layname)) (progn (setq layent (entget ename)) (if (and (= (getvar "tilemode") 0)(/= (getvar "cvport") 1)) (progn (command "vplayer" "thaw" layent "" "") ) (princ) ) ) ) You have to feed vplayer a name. Replace: (command "vplayer" "thaw" layent "" "") With: (command "vplayer" "thaw" [color=Red]layname[/color] "" "") Quote
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.