Author Topic: SelectionSet order (2)  (Read 425 times)

0 Members and 1 Guest are viewing this topic.

amc.dicsac

  • Newt
  • Posts: 105
  • Autocad 2008
SelectionSet order (2)
« on: March 20, 2017, 01:36:48 pm »
Hi.

I am trying to find a lisp that allows to maintain the order of a selection set, someone could help me with that information. :sleezy:

Thank you

<a href="http:/http://axprogramlisp.blogspot.pe" class="bbc_link" target="_blank">By Alexander Castro</a>

Lee Mac

  • Seagull
  • Posts: 11851
  • AutoCAD 2015 Windows 7 London, England
Re: SelectionSet order (2)
« Reply #1 on: March 20, 2017, 01:39:39 pm »
Since a set of objects may be selected to populate a selection set using any standard selection method (e.g. Window/Crossing/Window Polygon/Crossing Polygon/Fence/Group/Pick etc.), what 'order' are you referring to?

amc.dicsac

  • Newt
  • Posts: 105
  • Autocad 2008
Re: SelectionSet order (2)
« Reply #2 on: March 20, 2017, 01:46:55 pm »
Since a set of objects may be selected to populate a selection set using any standard selection method (e.g. Window/Crossing/Window Polygon/Crossing Polygon/Fence/Group/Pick etc.), what 'order' are you referring to?

When a selection is made, the average of each object's Handle is something similar to what "Jeff_M" posts

https://www.theswamp.org/index.php?topic=43477.msg487173#msg487173
<a href="http:/http://axprogramlisp.blogspot.pe" class="bbc_link" target="_blank">By Alexander Castro</a>

CAB

  • Global Moderator
  • Seagull
  • Posts: 10238
Re: SelectionSet order (2)
« Reply #3 on: March 20, 2017, 04:13:42 pm »
Since a set of objects may be selected to populate a selection set using any standard selection method (e.g. Window/Crossing/Window Polygon/Crossing Polygon/Fence/Group/Pick etc.), what 'order' are you referring to?
If you pick one at a time the order should remain as picked. Other methods of selection are somewhat unpredictable.
That is they are added to the set from upper right  or upper left if memory serves me.
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.

Lee Mac

  • Seagull
  • Posts: 11851
  • AutoCAD 2015 Windows 7 London, England
Re: SelectionSet order (2)
« Reply #4 on: March 20, 2017, 06:34:35 pm »
Personally, I would not rely on the order of entities appearing in a selection set obtained through a graphical selection method - I would only ever use the order of entities in a set obtained using the "X" mode string, which is known to be dependent on the sequence of objects in the drawing database.

If the selection is obtained from the user picking multiple objects, I would instead suggest using entsel within a while loop; other methods of selection (such as window/crossing) do not imply a selection order in my opinion.

amc.dicsac

  • Newt
  • Posts: 105
  • Autocad 2008
Re: SelectionSet order (2)
« Reply #5 on: March 20, 2017, 06:35:01 pm »
Since a set of objects may be selected to populate a selection set using any standard selection method (e.g. Window/Crossing/Window Polygon/Crossing Polygon/Fence/Group/Pick etc.), what 'order' are you referring to?
If you pick one at a time the order should remain as picked. Other methods of selection are somewhat unpredictable.
That is they are added to the set from upper right  or upper left if memory serves me.

Of course if I select one by one the order is maintained.

The problem is when it is selected in a massive way, it automatically creates a list by ordering the objects according to the Handle of each one.

I try to find some way to avoid ordering it that way,I think about of making a loop and store the selection with the "SSADD" function, some other idea would appreciate the support 
<a href="http:/http://axprogramlisp.blogspot.pe" class="bbc_link" target="_blank">By Alexander Castro</a>

roy_043

  • Water Moccasin
  • Posts: 1513
  • BricsCAD 16
Re: SelectionSet order (2)
« Reply #6 on: March 21, 2017, 04:31:49 am »
... a list by ordering the objects according to the Handle of each one...
The draworder also can have an impact on the order of elements in a selection set.

roy_043

  • Water Moccasin
  • Posts: 1513
  • BricsCAD 16
Re: SelectionSet order (2)
« Reply #7 on: March 21, 2017, 06:20:20 am »
The ssnamex function can be used to analyse how a selection set was created.