Anuncios

The Autodesk Community Forums has a new look. Read more about what's changed on the Community Announcements board.

Display color number of the layer of a selected object

Anonymous

Display color number of the layer of a selected object

Anonymous
No aplicable

Is there a way to display the color number of the layer of a selected objected? Maybe a lisp routine?

0 Me gusta
Responder
Soluciones aceptadas (1)
505 Vistas
4 Respuestas
Respuestas (4)

rkmcswain
Mentor
Mentor

What would you want it to display if the object has a color assigned to it, IOW, not "Bylayer"?

 

This might help: https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-layer-name-and-colour-from-selec...

R.K. McSwain     | CADpanacea | on twitter
0 Me gusta

Anonymous
No aplicable

I would want it to display the color of the layer of the object selected so that I can check what color that layer is currently on.

 

Basically, instead of using "xlist" to check what layer is on and then checking the layer in layer manager to check the color. It would save some time and be useful in some cases.

0 Me gusta

Kent1Cooper
Consultant
Consultant
Solución aceptada

(cdr (assoc 62 (tblsearch "layer" (cdr (assoc 8 (entget (car (entsel "\nSelect object to find its Layer's color: "))))))))

Kent Cooper, AIA
0 Me gusta

Anonymous
No aplicable

Thank you so much. This worked like a charm!

0 Me gusta