Author Topic: recent selection sets  (Read 1340 times)

0 Members and 1 Guest are viewing this topic.

ELOQUINTET

  • Guest
recent selection sets
« on: November 09, 2005, 01:46:35 PM »
my boss was telling me today  about a selection set tool that used to be a part of express tools around volume 7 or 8 that would remember the users last 10 selection sets. she said she loved that ability but has found nothing similar since. i was wondering if someone knows of a way to achieve this?

Sdoman

  • Guest
Re: recent selection sets
« Reply #1 on: November 09, 2005, 03:25:49 PM »
 
Never heard about that Express too.
What I do is to type some code directly in the Command window:
 
Code: [Select]
Command: (setq ss1 (ssget))
Select objects: Specify opposite corner: 2 found
Select objects:  <Selection set: 3>

Then when I need to retrieve the set at a command prompt, I do something like:

Code: [Select]
Command: m
MOVE
Select objects: !ss1
<Selection set: 3>
2 found
Select objects:
....

Just use a different variable name for each selection set you want to saved.
 
 

Sdoman

  • Guest
Re: recent selection sets
« Reply #2 on: November 11, 2005, 07:29:44 AM »
:whistle:

ELOQUINTET

  • Guest
Re: recent selection sets
« Reply #3 on: November 11, 2005, 09:05:53 AM »
thats a good tip but something more streamlined would be great. it would be nice to not have to name the sets. i'm also looking for something that doesn't required manual code for other users in my office who will never remember that.

Bob Wahr

  • Guest
Re: recent selection sets
« Reply #4 on: November 11, 2005, 11:53:19 AM »
OK, I punt.  I tried to figure it out but don't have the time or lisp to do it.  Thought about using an EndCommand VBA event but without doing an item by item comparison of P1 and the last selection set made I can't figure it out.  I figured that I could catch a selection set being added to the dwg via VBA but it doesn't appear to be the case.  Probably could if I had the time.  Your best bet is if someone who is good with vlisp reactors (hint hint LE) was to come along and wrap this in a reactor that fired when a selection set was made.  Then you could !p1 !p2 !p3, etc. to get to them
Code: [Select]
((setq p10 p9)
(setq p9 p8)
(setq p8 p7)
(setq p7 p6)
(setq p6 p5)
(setq p5 p4)
(setq p4 p3)
(setq p3 p2)
(setq p2 p1)
(setq p1 (ssget "P"))
)

LE

  • Guest
Re: recent selection sets
« Reply #5 on: November 11, 2005, 12:50:09 PM »
I had posted a sample about getting a selection set in the lisp forum - that can change the "Previous" to "Last ones copied"... I forgot the topic, sorry.