change color of all layers using command line

change color of all layers using command line

htls69
Advocate Advocate
7,830 Views
1 Reply
Message 1 of 2

change color of all layers using command line

htls69
Advocate
Advocate

I want to change all layer in a drawing to a color 8 is it possible to do it with the command line

 

Allen Robberson
Credit where credit is due! Give kudos or accept as solution whenever you can.
0 Likes
Accepted solutions (1)
7,831 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable
Accepted solution

Prefix the layer command with a dash

-layer c 8 * [enter twice]

 

If you're not familiar with wildcards, the asterisk means everything.  You could enter BOB* and it would change only the layers starting with BOB, or you could enter *WEAVE and it would change only the layers ending in WEAVE, or you could enter BOB*WEAVE and it would change only the layers that started with BOB AND ended in WEAVE.

 

a * is any number of letters/numbers

a ? is a single letter/number

a ~ is everything EXCEPT the following

 

entering

-layer c 8 *|cl?bm* [enter twice]

 will change ALL XREF layers beginning with CL have ONE wildcard letter/number then the letters BM followed by any number of letters/numbers to color 8