Jump to content

Recommended Posts

Posted

Hi all,
I’m looking for a custom AutoLISP script (for batch freezing/thawing layers before printing). some particular layer i need for drawing internal circulation. bet they are not required during submission. is there any other method ther?

Posted

Depends on what you want to do. this will freeze a layer of the entity you select is on.

 

(defun c:FreezeEntity (/ ent layN layO)
  (while (setq ent (entsel "\nSelect an entity to freeze layer: "))
    (setq layN (cdr (assoc 8 (entget (car ent)))))
    (setq layO (vla-item (vla-get-Layers (vla-get-ActiveDocument (vlax-get-Acad-Object))) layN))
    (vla-put-Freeze layO :vlax-true)
    (prompt (strcat "\nLayer \"" layN "\" has been frozen."))
  )
  (princ)
)

 

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