Ikkukp Posted 18 hours ago Posted 18 hours ago 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? Quote
mhupp Posted 10 hours ago Posted 10 hours ago (edited) 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) ) -Edit Why not just have the calculations on defpoints or some other layer that is set not to print. (vla-put-Plottable layo :vlax-false) Edited 5 hours ago by mhupp 1 Quote
Steven P Posted 6 hours ago Posted 6 hours ago Can also put these into a routine: (command "-layer" "ON" "ListofLayers, EachLayerSeperated, Withcomma" "") ; Turns layer ON.. try 'OFF' (command "-layer" "FREEZE" "ListofLayers, EachLayerSeperated, Withcomma" "") ; Freezes layer, ty 'Thaw' as well For completion: (command "-layer" "SET" "LayerName" "") ; Sets current layer MHUPPs probably runs faster (like milliseconds) and a nice option to choose the layer, my ideas maybe better if the layer names are set and can be hard coded into the routine... but useless if each drawing / project uses a different name 1 Quote
BIGAL Posted 1 hour ago Posted 1 hour ago If you use a plot lisp can set layers off/frozen do plot then turn back on. If using layouts can set layer frozen in a viewport but see in Model, may be the simplest way. 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.