Selection set that goes through a single point

Selection set that goes through a single point

saitoib
Advocate Advocate
1,118 Views
10 Replies
Message 1 of 11

Selection set that goes through a single point

saitoib
Advocate
Advocate
Hi all!

Can I use ssget to create a selection set that goes through a single point?

Thank you.
Saitoib
0 Likes
Accepted solutions (1)
1,119 Views
10 Replies
Replies (10)
Message 2 of 11

hak_vz
Advisor
Advisor

Try to be more specific. What you want to select at that single point?

For a start read this ssget guide from Lee Mac, part about logical filters.

Miljenko Hatlak

EESignature

Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.
0 Likes
Message 3 of 11

ВeekeeCZ
Consultant
Consultant

Sure...  (ssget pt)

0 Likes
Message 4 of 11

saitoib
Advocate
Advocate

@hak_vz 

@ВeekeeCZ 

I'm sorry. I didn't explain it well enough.
For example, in the following figure, how can I select the three lines that pass through the point (100 0 0)?

 

line 0,0 110,0

line 90,0 200,0

line 100,0 100,100

 

Saitoib
0 Likes
Message 5 of 11

ВeekeeCZ
Consultant
Consultant

I typically calculate a small rectangle and use crossing selection.

(ssget "_C" '(99 -1) '(101 1))

 

Edited: Kent, thx for the heads up.

0 Likes
Message 6 of 11

Kent1Cooper
Consultant
Consultant

@ВeekeeCZ wrote:

Sure...  (ssget pt)


That finds only one object.

Kent Cooper, AIA
0 Likes
Message 7 of 11

Kent1Cooper
Consultant
Consultant

@ВeekeeCZ wrote:

I typically calculate a small rectangle and use a window selection.

(ssget "_W" '(99 -1) '(101 1))


I think you mean "_C".

Kent Cooper, AIA
Message 8 of 11

Kent1Cooper
Consultant
Consultant

@saitoib wrote:

.... in the following figure, how can I select the three lines that pass through the point (100 0 0)?


According to the description in Help for (ssget), this ought to do that:

(setq ss (ssget "_:E" '(100.0 0.0 0.0)))

 

but for some reason I haven't figured out, it gives me a "bad point argument" error message.

 

EDIT:  It seems that the :E mode only works with User pick of a point -- see >this< and >here<.

But you can use a Crossing selection without building a larger box, but just use the same point for both corners:

(setq pt '(100.0 0.0 0.0))
(setq ss (ssget "_C" pt pt))

Kent Cooper, AIA
0 Likes
Message 9 of 11

hak_vz
Advisor
Advisor

@saitoib wrote:

@hak_vz 

@ВeekeeCZ 

I'm sorry. I didn't explain it well enough.
For example, in the following figure, how can I select the three lines that pass through the point (100 0 0)?

 

line 0,0 110,0

line 90,0 200,0

line 100,0 100,100

 


You didn't read the text at link that I provided. There is actually a sample for similar case.

 

Miljenko Hatlak

EESignature

Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.
0 Likes
Message 10 of 11

hak_vz
Advisor
Advisor
Accepted solution

@saitoib wrote:

@hak_vz 

@ВeekeeCZ 

I'm sorry. I didn't explain it well enough.
For example, in the following figure, how can I select the three lines that pass through the point (100 0 0)?

 

line 0,0 110,0

line 90,0 200,0

line 100,0 100,100

 


Untitled.png

 

Command: (setq ss (ssget "c" '(100 0 0) '(100 0 0)))
<Selection set: 10>
Command: M
MOVE
Select objects: !ss
<Selection set: 10>
3 found

 

Miljenko Hatlak

EESignature

Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.
0 Likes
Message 11 of 11

saitoib
Advocate
Advocate

@hak_vz 

Thank you very much.
I didn't know there was a way to do this.
I was able to solve the problem.

Saitoib