Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Force objects color, linetype and lineweight

10 REPLIES 10
Reply
Message 1 of 11
jbear0000
873 Views, 10 Replies

Force objects color, linetype and lineweight

I have some legends that contain many layers and I'd like to clean them out. I would like to change all of the linework in the legend to layer 0, but have it retain the color, linetype and lineweight that it currently has. Does anyone know of a lisp that could do this?

10 REPLIES 10
Message 2 of 11
Kent1Cooper
in reply to: jbear0000

If the Legend is a Block, try this.  It only does color and linetype, but could be edited easily enough to include lineweight.

Kent Cooper, AIA
Message 3 of 11
jbear0000
in reply to: Kent1Cooper

That put all of the linework on layer 0, but it didn't hold any of the colors or linetypes.

Message 4 of 11
dbroad
in reply to: jbear0000

What you want to do sounds good but the legend should have the same structure as the symbols in the drawings (layer, color, linetype, etc.).  In general all properties of all objects should be bylayer.  Objects internal to blocks that should inherit the block properties should be set to byblock.  All appearance control should be done by layering.  What you are doing is taking a large step backward in terms of standards.

 

I leave it to others to let you accomplish this step backwards more easily.

Architect, Registered NC, VA, SC, & GA.
Message 5 of 11
Kent1Cooper
in reply to: jbear0000


@jbear0000 wrote:

That put all of the linework on layer 0, but it didn't hold any of the colors or linetypes.


Hmmm --  It was working at the time I posted it back then, but I'll have to investigate,,,,

 

EDIT: Meanwhile, you could try out some of the other routines on that same thread, which may do it for you.

 

FURTHER EDIT:  I just tried it, and it's still working for me here.  I'm on an older version, though -- I'll have to try it again when I get to where I have Acad2015.  I'm not sure what about it might be version-dependent, except for the block-name part that's already dealt with.

Kent Cooper, AIA
Message 6 of 11
jbear0000
in reply to: dbroad

dboard, Don't tell me how to do my standards and drafting, there are reasons we want to do it this way, which I have no need to explain. If you can't offer help with the question I am asking, don't respond.

Message 7 of 11
jbear0000
in reply to: Kent1Cooper

Thank you Kent1Cooper

Message 8 of 11
3wood
in reply to: jbear0000

You can try attached CHZ20.vlx, which can changed everything inside a block to layer 0 while retain subentities' own color and linetype. But it is not able to retain the lineweight.

Settings as below:

chz20.png

Message 9 of 11
dgorsman
in reply to: jbear0000

Steady on lad.  People are here volunteering to help; the help offered may not be *exactly* what you are after but is still helpful.  dbroad is one of our best, long term contributors and his advice is sound.  You may have reasons for doing things this way but you didn't elaborate on those reasons (or even the fact that you are restricted to doing it this way).

----------------------------------
If you are going to fly by the seat of your pants, expect friction burns.
"I don't know" is the beginning of knowledge, not the end.


Message 10 of 11
3wood
in reply to: dgorsman

I agree with dgorsman, the Forums is for discussion, we welcome different ideas. Sometime although an idea seems not the direct answer, it may inspire a new solution.

Message 11 of 11
braudpat
in reply to: jbear0000

 

Hello from France

 

Maybe you could use this french VLisp routine (from Patrick_35) "RB_Zero" which send "back" to Layer ZERO all block's entities without editing Color, Linetype, Lineweight ...

 

But you can easily edit the routine at lines 100 / 103 / 106  to do more ...

 

I hope "RB_Zero" can help you ...

 

Patrice ( Supporting Troops ) - Autodesk Expert Elite
If you are happy with my answer please mark "Accept as Solution" and if very happy please give me a Kudos (Felicitations) - Thanks

Patrice BRAUD

EESignature


Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost