Jump to content

Recommended Posts

Posted

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)))

)

)

)

)

Posted

How about (command "REGENALL") -David

Posted

is there a way to thaw a viewport layer using assoc 70, and using subst (cons...?

Posted
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

Posted

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)

)

)

)

Posted

maybe this will work for you

(command "vplayer" "thaw" (cdr (assoc 2 layent)) "" "")

Posted
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] "" "")

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...