SSGET to select a polyline using two coordinates as filters

SSGET to select a polyline using two coordinates as filters

Anonymous
Not applicable
5,938 Views
20 Replies
Message 1 of 21

SSGET to select a polyline using two coordinates as filters

Anonymous
Not applicable

Hello,

Why the SSGET command line using StartPoint AND EndPoint variables/filters doesn't work?

 

(setq SelSet (ssget "_:L" '((0 . "*POLYLINE")))) 
(setq na1 (ssname SelSet 0)) 
(setq obj (vlax-ename->vla-object na1))
(setq StartPoint (vlax-curve-getStartPoint obj) )
(setq EndPoint (vlax-curve-getEndPoint obj) )
(setq ss1 (ssget "C" StartPoint EndPoint '((0 . "*POLYLINE"))  (-4 . "=,=,*") (10 (car StartPoint) (car (cdr StartPoint)) 0.0 )))

 

StartPoint AND EndPoint vertices can be in any position/sequence, not necessary the first vertex coordinate.

The command still incomplete because I need to ADD EndPoint on the filters. 

 

The goal is to complete the RED polyline with the vertices of the WHITE one (check image). It's the next step of the code.

 

Thanks in advance + regards,

lzucco

0 Likes
Accepted solutions (4)
5,939 Views
20 Replies
Replies (20)
Message 21 of 21

Anonymous
Not applicable

best solution I found for solving

minimum distance between two objects

https://autocadtips1.com/2017/03/13/lisp-version-of-closest-distance-between-two-objects/

 

 

0 Likes