AutoCAD/Turning Off Layers which contain blocks
Expert: Bill DeShawn - 8/2/2009
QuestionQUESTION: I have a large number of Blocks, which have been created with some of their components on layer 0, and others on various other layers. The reason for using layers other than layer 0 is so that features residing on these layers made be selectively displayed.
When these Blocks are inserted on a particular layer, I would like these blocks no NOT be visible when that layer has been turned off. This used to work, but now only the block entities which were created on layer 0 are turned off, while block entities created on other layers remain visible.
ANSWER: Bryan
What happens when you freeze the layer instead of turning it off? I believe that if you freeze the layer on which the block was inserted, the block will not be displayed, which apparently is the outcome you seek at this time.
If you insert the block on a particular layer, then that particular layer should be the one you turn off. You did that, so it's only reasonable to expect that all the contents of the layer would not display. So that said, I agree with you. In my experience, I have found that AutoCAD acts a lot more logically when I freeze and thaw layers than when I turn them on and off.
Also, we have even more control with VPLAYER overrides, working in layouts and freezing and thawing layers in the viewport. When working with layer overrides like this, you need to keep in mind that the layout is also recognized as a viewport. The viewports within a layout are really nested viewports. If using that method, to ensure that all layers that are displaying that are supposed to, it's a good idea to thaw all layers before plotting the layout.
Let me know how it goes
Bill DeShawn
http://my.sterling.net/~bdeshawn
---------- FOLLOW-UP ----------
QUESTION: Thanks for your response Bill.
Freezing the layer does in fact produce the desired result. I do however have a need to achieve the same effect by turning the layer off because it is used in an AutoLisp routine, which has worked for years but now behaves as described. The AutoLisp file is automatically run when I load any drawing.
Is there a system variable or something of the sort which may be causing this or perhaps does AutoCad now handle layers differently than it used to? I also recall that Freezing a layer used to not turn off its visibility but only cause the layer to not be regenerated until thawed. Am I imagining all this?
Thanks once again for your time,
Bryan
AnswerBryan:
Autodesk does in fact change they way their commands behave from time to time, and sometimes (although rarely) without ever telling us. Case in point ATTEDIT in Rel 13, corrected in R14. What version of AutoCAD are you running?
Also, if the LISP routine is raw code, rather than protected, may I have a look at it? Do you think it would cause problem for you if it froze the layer(s) as opposed to turning the layers off?
To get my email address, you can go to my website and click on the email icon at the bottom of the page.
Bill DeShawn
http://my.sterling.net/~bdeshawn