With the SETBYLAYER command you can set the selected properties of selected DWG drawing objects (including objects nested in blocks) to the value "ByLayer", i.e. so that they inherit the property of the layer in which they are inserted. For example, their color from the layer color.
Sometimes a related SETBYBLOCK command would be useful, which would set the properties of objects to "ByBlock" in this way, in bulk, and so e.g. all objects in a block or array would mimic the properties of the main object - e.g. block color, array color.
Such command does not exist in AutoCAD but it can be added into your AutoCAD or AutoCAD LT using the freeware LISP utility SetByBlock. Download it from Download, load it into AutoCAD using APPLOAD and run it by typing SETBYBLOCK.
Select the objects to change and specify which properties do you want to set to ByBlock (by default: Color, Linetype and Lineweight - can be preset with the LISP variable _SetByBlockMode similarly to SETBYLAYERMODE). Specify whether to process nested objects in blocks and arrays as well. The utility will then bulk change the specified properties of the selected entities to ByBlock.