CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products []
CZ | EN | DE
Login or
  Visitors: 6450

CAD tip CAD tip # 5131:

Question CAD 
 %  platform  category 
Q - question

How to place dimensions or hatches automatically to preset layers?

A - answer If you want to draw your dimensions, hatches, points or text always to fixed predefined layers, you can use several methods how to do this in plain AutoCAD (some vertical AutoCAD versions and add-ons offer this function automatically):
  1. you can customize (no programming) your AutoCAD toolbars so that the dimension functions will always start with a layer switch command:
  2. place dim commands or hatch patterns onto a user Palette (Ctrl+3) and in the properties of these items (rt-click, Properties) set the given value for the Layer property; if you start commands from palettes, this is the best option for you
  3. use a .LSP program to redefine (_UNDEFINE) the _DIMxxxx commands so that they will always start with a layer switch command (_-LAYER)
  4. attach a reactor to the dimensioning commands which will automatically switch to a specified layer (and then switch the layer back)
  5. you can also change layer ex-post - use QSELECT or the Properties window to select all dimensions and then change their Layer property to the target layer
Probably the most effective way are the palettes (2) and reactors (4). As an example of such reactor you can use the free utility AutoLay (see Download) or FLay (see Download), which places all drawn dimensions, hatches and texts to fixed predefined layers. Just load the LISP utility into AutoCAD (APPLOAD) and switch it on with the AutoLay (or FLay) command.

E.g. for FLay, you just prepare a simple text file with layer names for the individual object types (this file is loaded by the FLay utility). That's all, you can use standard commands. An example (hatches, red texts):

* Texts 1
* Hatch

100% *  CAD 
21.7.2006    63827×   FAQ  
Prices - CAD eShop:
applies to: AutoCAD ·

See also:
Tip 13288:LayoutLF - automatic switching of group layer filters.
Tip 13014:StickLay - unchangable, fixed layers for selected DWG objects.
Tip 12335:The FLAY utility suddenly places texts and dimensions in wrong layers.
Tip 11967:How to apply a changed drawing template (DWT) to existing drawings?
Tip 11780:How to rename layouts by a specific attribute of the title block?

Back   All CAD Tips

Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD:    OS:    Categ: 
Text:  FAQ glossary   

Extend your AutoCAD LT productivity with our popular add-on
CADstudio LT Extension More info

Please use these tips at your own risk.
Arkance Systems is not responsible for possible problems that may occur as a result of using any of these tips.