Author Topic: looking for a layering routine  (Read 3491 times)

0 Members and 1 Guest are viewing this topic.

ronjonp

  • Needs a day job
  • Posts: 7529
looking for a layering routine
« on: November 23, 2005, 01:12:26 PM »
Here's the story...get a drawing from a client. Everything is on layer 0 but all the objects are color by object.

I was looking for a routine that grabs objects by color and puts them on a layer. I did a search but CAB's link to the routine I think I need is broken.

http://www.theswamp.org/forum/index.php?topic=5300.0

thanks,

Ron


Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

Mark

  • Custom Title
  • Seagull
  • Posts: 28762
Re: looking for a layering routine
« Reply #1 on: November 23, 2005, 01:14:49 PM »
Try this one from Jeff_M

color2layer.LSP

http://www.theswamp.org/lilly_pond/

TheSwamp.org  (serving the CAD community since 2003)

ronjonp

  • Needs a day job
  • Posts: 7529
Re: looking for a layering routine
« Reply #2 on: November 23, 2005, 01:24:20 PM »
Thanks Mark :)

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

Serge J. Gianolla

  • Guest
Re: looking for a layering routine
« Reply #3 on: November 23, 2005, 11:05:56 PM »
You do not need a routine for that. Quick Select used in Properties will achieve same result [and will help the ones on LT not to think they are 2nd class citizens!] :laugh:

Edited: 2nd class instead of 2nd hand  :ugly:
« Last Edit: November 24, 2005, 12:45:45 AM by Serge J. Gianolla »

ronjonp

  • Needs a day job
  • Posts: 7529
Re: looking for a layering routine
« Reply #4 on: February 01, 2006, 12:45:29 PM »
You do not need a routine for that. Quick Select used in Properties will achieve same result [and will help the ones on LT not to think they are 2nd class citizens!] :laugh:

Edited: 2nd class instead of 2nd hand  :ugly:

How would quick select scan the whole drawing and automatically place every object on the appropriate layer? Is qselect more powerful than the filter command? I was under the impression they were about the same.....

Ron

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

CAB

  • Global Moderator
  • Seagull
  • Posts: 10401
Re: looking for a layering routine
« Reply #5 on: February 01, 2006, 02:08:28 PM »
I've reached the age where the happy hour is a nap. (°¿°)
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

ronjonp

  • Needs a day job
  • Posts: 7529
Re: looking for a layering routine
« Reply #6 on: February 01, 2006, 02:24:00 PM »
Thanks CAB. Jeffs routine worked great when I needed it. My new question is "Is qselect more powerful than the filter command?"
I always thought they were kinda one in the same.

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

Jeff_M

  • King Gator
  • Posts: 4096
  • C3D user & customizer
Re: looking for a layering routine
« Reply #7 on: February 01, 2006, 02:39:45 PM »
Ron, in my experience the Filter command is far more powerful than Qselect.

Filter allows you to:
 use multiple filters at the same time
 save the settings for later use
 get more than one type object
 etc.

Qselect is 'quick', but you pay a penalty for it by not being able to do the above.....

ronjonp

  • Needs a day job
  • Posts: 7529
Re: looking for a layering routine
« Reply #8 on: February 01, 2006, 03:02:08 PM »
Jeff,

I guess I am on the right track. IMO filter is one of the most powerful commands in AutoCAD. I was just wondering about the differences between the two since I have so very little experience with qselect. I was thinking maybe Serge had stumbled upon something with it that merited looking into.

Thanks for the reply.

Ron
« Last Edit: February 01, 2006, 05:02:51 PM by ronjonp »

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

danny

  • Guest
Re: looking for a layering routine
« Reply #9 on: February 01, 2006, 04:33:08 PM »
color2layer.lsp is very helpful with multiple files and ran through a script.  Saved me loads of time, mahalo to jeff.

Serge J. Gianolla

  • Guest
Re: looking for a layering routine
« Reply #10 on: February 01, 2006, 07:28:03 PM »
Hi Ron,

I understood you had a dwg with objects having different colours and you were after selecting them by colour. With QSelect, work on entire dwg, Object type on Multiple Properties set on Color, then = say RED, and all red objects are selected to be transfered to layer. QSelect more powerful than Filter, maybe not but less cumbersome to use!
As for:
 save the settings for later use  Non-issue for majority of users
 use multiple filters at the same time and get more than one type object Tick box Append to current selection set
 Sorry Jeff, my opinion only :angel:

ronjonp

  • Needs a day job
  • Posts: 7529
Re: looking for a layering routine
« Reply #11 on: February 02, 2006, 09:29:08 AM »
Hi Ron,

I understood you had a dwg with objects having different colours and you were after selecting them by colour. With QSelect, work on entire dwg, Object type on Multiple Properties set on Color, then = say RED, and all red objects are selected to be transfered to layer. QSelect more powerful than Filter, maybe not but less cumbersome to use!
As for:
 save the settings for later use  Non-issue for majority of users
 use multiple filters at the same time and get more than one type object Tick box Append to current selection set
 Sorry Jeff, my opinion only :angel:

IMO

Jeff's routine is filter on steroids :). In Jeff's routine you can specify what color goes on what layer (and create the layer automatically) and changes everything accordingly in one swoop. I understand selection sets of objects that have certain properties...but if you have 100 objects all different colors, then you would have to qselect 100 times and layer accordingly right (as well as make the layers)? Or maybe I'm missing something.

Ron

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

Jeff_M

  • King Gator
  • Posts: 4096
  • C3D user & customizer
Re: looking for a layering routine
« Reply #12 on: February 02, 2006, 06:55:23 PM »
<snip>
Sorry Jeff, my opinion only :angel:
No reason to be sorry, Serge! Both options are there for our use. I never said that Qselect wasn't good, I just answered Ron's question about which is more powerful. And I stand by what I said. I will say, however, that I use Qselect far more often than Filter because, as you said, it is less cumbersome.

That being said, NEITHER of them is very good for what the OP was posting about, which is why my lisp works so well for those that have used it :-P  Try using Qselect or Filter, as Ron pointed out, in a drawing with 1 layer ("0"), 10,000 entities with 100 different colors and place each object of each color on it's own layer with the name of the layer matching that color. You'd first have to go through and note which colors are used, create each layer, use Qselect 100 times........just a wee bit too much labor for me.

Jeff