[Search tip detail and code files using keywords, tip number, author name, etc ]
 
Use Tool Palettes to Manage Layers
Tip# 3177 By George Voelcker On 05-Apr-2009
4
Rated By 1 users
Categories : Tool Palettes
Software type : AutoCAD 2009
Rename File To : No Files to download.
Using tool palettes and custom commands to manage layer states.

George Voelcker sent us a method using tool palettes and custom commands to manage layer states.

"After seeing the tip on layer macros (Tips & Tools Weekly Vol. 14, No. 6), I thought I would share the way I control xref (or any group) layers. First of all, most of my tools are stored in tool palettes with palettes named for the task I am doing: 'Foundation' for all the tools, styles, dynamic blocks, hatches etc. I need for working on a Foundation Sheet. Regarding layer visibility (Freeze Thaw On Off), I have a palette called 'ON_OFF' that has all the combinations of layer visibility tools for layers I need to control.

"In a set of architectural drawings for an apartment building, I need a different set of xref layers visible than in a set of structural drawings for the same building (the colors and linetypes are also different). To control visibility I'll use a Palette tool with a 'Command String' of something like the following [a string of text that's broken here for illustration purposes but would run as a single line]:

-LAYER;FREEZE;*BACKGROUND_FOUNDATION,*CONC_HATCH,*CONC_HATCH_2,*DOOR,*DOOR_FILL, *DOOR_SWING,*FLATWORK,*FLATWORK_2;;

"Anyway, as you can see, the '*' catches all the xref layers and freezes them (i.e. all the xrefs that have the layer 'BACKGROUND_ FOUNDATION' get frozen). This method works great if all your floor plan base drawings have all the same layers. I like to bring layers in from 'Design Center' rather than using a prototype. That way, if I add some layers to a project I have access to them, through 'DC' without having to keep updating a prototype.

"Obviously anything can be done here that is part of the -layer command as well as wildcards for layer names."

Notes from Cadalyst Tip Patrol: Tool palettes are very easy to customize. They are also easy to migrate to a new version of AutoCAD. Tool palettes can be used for many things, commands, blocks, and now even layer control.

 

Average Rating:
4


User comments


Log In