SelectOnScreen Method

SelectOnScreen Method

Anonymous
Not applicable
295 Views
3 Replies
Message 1 of 4

SelectOnScreen Method

Anonymous
Not applicable
I am wondering (hoping) that I can find out the point that is selected while
building a selection set with the SelectOnScreen method. I know that I can
use the Utility.GetPoint method and then GetCorner to create a window and
then build the selection set based on those points, the problem is that I
may need to individually pick elements sometimes, a window will not always
work. I want to record the position that the very first pick occurs at
whether it is the start of a window or selecting an individual element. I
also know that i can just use GetPoint first, then SelectOnScreen to
accomplish what I need to, however that will be forcing an extra pick that I
dont want to do unless I absolutely have to.

Any ideas would be greatly appreciated.

Thank you.
0 Likes
296 Views
3 Replies
Replies (3)
Message 2 of 4

Anonymous
Not applicable
Tim,

The SelectOnScreen method works just like selecting objects in AutoCAD [meaning you can add/delete items from the selection set just like you can in AutoCAD]. There are numerous ways of creating a selection set including window, crossing-window, fence, an individual entity selection and all within the call to the SelectOnScreen method.

Joe
--
0 Likes
Message 3 of 4

Anonymous
Not applicable
Let me take a step back and see if i can describe
what I am after.  I am going to be selecting a group of objects with the
SelectOnScreen method.  Also, the position of the objects are important to
some sorting routines that i have.  The most efficient way for my routine
to run would be for the point to be stored in a variable where first
click in the SelectOnScreen method occurs.  Basically I need a startpoint
for the sorting.  I know that I can accomplish what I need by using
Utility.GetPoint to set the startpoint and then use the SelectOnScreen method,
however that would force another mouse-click that I would like to avoid if
possible.  The ideal situation would allow the points (specifically the
first point) that are selected in the SelectOnScreen method to be stored
somewhere so that my sorting routines will work correctly.  I have a
feeling that I am not going to be able to get this information, however I just
wanted to check with the newsgroup to see if anyone had any ideas or knew if
this was possible or not. 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
Tim,

The SelectOnScreen method works just like selecting objects in AutoCAD
[meaning you can add/delete items from the selection set just like you can in
AutoCAD]. There are numerous ways of creating a selection set including
window, crossing-window, fence, an individual entity selection and all within
the call to the SelectOnScreen method.

Joe
--

0 Likes
Message 4 of 4

Anonymous
Not applicable
Tim Jendro wrote:
> Let me take a step back and see if i can describe what I am after. I am
> going to be selecting a group of objects with the SelectOnScreen
> method. Also, the position of the objects are important to some sorting
> routines that i have. The most efficient way for my routine to run
> would be for the point to be stored in a variable where first click in
> the SelectOnScreen method occurs. Basically I need a startpoint for the
> sorting. I know that I can accomplish what I need by using
> Utility.GetPoint to set the startpoint and then use the SelectOnScreen
> method, however that would force another mouse-click that I would like
> to avoid if possible. The ideal situation would allow the points
> (specifically the first point) that are selected in the SelectOnScreen
> method to be stored somewhere so that my sorting routines will work
> correctly. I have a feeling that I am not going to be able to get this
> information, however I just wanted to check with the newsgroup to see if
> anyone had any ideas or knew if this was possible or not.

Maybe you could use GetEntity for the initial pick, then move to the
SelectOnScreen after something has been selected and just add the first
entity to the set after selection is finished.

......I guess that still leaves you with the extra pick, though.

.......then again, I don't know if GetEntity will return the point if an
object isn't selected. If so, this should work fine, I think.
0 Likes