[Search tip detail and code files using keywords, tip number, author name, etc ]
 
    For tip to function correctly, you must ensure that the downloaded file name matches the file name
    displayed in the Rename File To field. Please rename downloaded files when necessary.
Find and Change Objects by Color Setting
Tip# 3032 By Ed Jobe On 01-Dec-2008
4
Rated By 1 users Downloaded : 524
Categories : Layer Properties, Programming Examples
Software type : AutoCAD 2008
Rename File To : ColorToByLayer.Bas
This VBA macro reads through the current drawing layouts and changes any entity objects that have a color setting that is not "by layer."

This excellent little VBA macro named ColorToByLayer reads through the current drawing layouts and changes any entity objects that have a color setting that is not "by layer." Changed entities are moved to a new layer named "CBL_" plus the color number. The entity color code is then reset to be "by layer." To use Find and Change Objects by Color Setting,  you need to launch AutoCAD’s VBAide, then select the File and Import File . . . and navigate to where the BAS file is located. The BAS file will load into a module. Select the module in the project window pane and then click the run button (F5 key). The macro ColorToByLayer should be available to run, so click it, and the rest is automatic. This utility is a great VBA example for those looking to learn how to use this marvelous customization tool.

 

Average Rating:
4


User comments


Log In