<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: SSGET to select a polyline using two coordinates as filters in Visual LISP, AutoLISP and General Customization Forum</title>
    <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413606#M96484</link>
    <description>&lt;P&gt;What do you mean by "&lt;SPAN style="font-family: inherit;"&gt;Where to find?" Where &lt;STRONG&gt;&lt;EM&gt;what&lt;/EM&gt; &lt;/STRONG&gt;to find? &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;Syntax? I guess you do understand the syntax of this short line... or do you?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;Point? You don't understand how the pnt&amp;nbsp;is supplied/calculated? &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;?? Or something else?&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 20 Nov 2018 14:39:39 GMT</pubDate>
    <dc:creator>ВeekeeCZ</dc:creator>
    <dc:date>2018-11-20T14:39:39Z</dc:date>
    <item>
      <title>SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408912#M96470</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Why the SSGET command line using StartPoint AND EndPoint variables/filters doesn't work?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(setq SelSet (ssget "_:L" '((0 . "*POLYLINE"))))&amp;nbsp;&lt;BR /&gt;(setq na1 (ssname SelSet 0))&amp;nbsp;&lt;BR /&gt;(setq obj (vlax-ename-&amp;gt;vla-object na1))&lt;BR /&gt;(setq StartPoint (vlax-curve-getStartPoint obj) )&lt;BR /&gt;(setq EndPoint (vlax-curve-getEndPoint obj) )&lt;BR /&gt;(setq ss1 (ssget "C" StartPoint EndPoint '((0 . "*POLYLINE"))&amp;nbsp; (-4 . "=,=,*") (10 (car StartPoint) (car (cdr StartPoint)) 0.0 )))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;StartPoint AND EndPoint vertices can be in any position/sequence, not necessary the first vertex coordinate.&lt;/P&gt;&lt;P&gt;The command still incomplete because I need to ADD EndPoint on the filters.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance + regards,&lt;/P&gt;&lt;P&gt;lzucco&lt;/P&gt;</description>
      <pubDate>Sun, 18 Nov 2018 12:20:43 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408912#M96470</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-18T12:20:43Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408942#M96471</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I did not get your point totally.......&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Why the SSGET command line using StartPoint AND EndPoint variables/filters doesn't work?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(setq SelSet (ssget "_:L" '((0 . "*POLYLINE"))))&amp;nbsp;&lt;BR /&gt;(setq na1 (ssname SelSet 0))&amp;nbsp;&lt;BR /&gt;(setq obj (vlax-ename-&amp;gt;vla-object na1))&lt;BR /&gt;(setq StartPoint (vlax-curve-getStartPoint obj) )&lt;BR /&gt;(setq EndPoint (vlax-curve-getEndPoint obj) )&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;(setq ss1 (ssget "C" StartPoint EndPoint '((0 . "*POLYLINE"))&amp;nbsp; (-4 . "=,=,*") (10 (car StartPoint) (car (cdr StartPoint)) 0.0 )))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;StartPoint AND EndPoint vertices can be in any position/sequence, not necessary the first vertex coordinate.&lt;/P&gt;&lt;P&gt;The command still incomplete because I need to ADD EndPoint on the filters.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance + regards,&lt;/P&gt;&lt;P&gt;lzucco&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But the Red line should be like.......&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;(setq ss1 (ssget "C" StartPoint EndPoint (list '(0 . "*POLYLINE") (cons 10 (list (car StartPoint) (car (cdr StartPoint)) 0.0 )))))&lt;/PRE&gt;&lt;P&gt;And what about&amp;nbsp; "(-4 . "=,=,*")"....&lt;/P&gt;</description>
      <pubDate>Sun, 18 Nov 2018 13:17:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408942#M96471</guid>
      <dc:creator>dbhunia</dc:creator>
      <dc:date>2018-11-18T13:17:59Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408955#M96472</link>
      <description>&lt;P&gt;Thanks a lot!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also want to include EndPoint in the filter because I'ld&amp;nbsp;like to select only polylines that contains both StarPoint AND EndPoint vertices, that's why I was trying ("=,=,*") = coordinate X,&amp;nbsp; = coordinate Y, * any Z coordinate.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The result of following command should be 2 polylines (RED and WHITE)&lt;/P&gt;&lt;P&gt;(setq ss1_qt (sslength ss1))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then I remove from the ss1 the manual polyline selected using&amp;nbsp;&lt;/P&gt;&lt;P&gt;(if (ssmemb na1 ss1)&lt;BR /&gt;(ssdel na1 ss1)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The result of ss1 will be only the polyline I was looking for. (WHITE)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 18 Nov 2018 13:43:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408955#M96472</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-18T13:43:14Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408976#M96473</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;Thanks a lot!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;I also want to include EndPoint in the filter because I'ld&amp;nbsp;like to select only polylines that contains both StarPoint AND EndPoint vertices, that's why I was trying ("=,=,*") = coordinate X,&amp;nbsp; = coordinate Y, * any Z coordinate.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The result of following command should be 2 polylines (RED and WHITE)&lt;/P&gt;&lt;P&gt;(setq ss1_qt (sslength ss1))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then I remove from the ss1 the manual polyline selected using&amp;nbsp;&lt;/P&gt;&lt;P&gt;(if (ssmemb na1 ss1)&lt;BR /&gt;(ssdel na1 ss1)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The result of ss1 will be only the polyline I was looking for. (WHITE)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For that try this.....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;(setq ss1 (ssget "_A" (list '(0 . "*POLYLINE") (cons 10 (list (car EndPoint) (car (cdr EndPoint)) 0.0 )) (cons 10 (list (car StartPoint) (car (cdr StartPoint)) 0.0 )))))&lt;/PRE&gt;</description>
      <pubDate>Sun, 18 Nov 2018 14:09:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8408976#M96473</guid>
      <dc:creator>dbhunia</dc:creator>
      <dc:date>2018-11-18T14:09:46Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8409023#M96474</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;I also want to include EndPoint in the filter because I'ld&amp;nbsp;like to select only polylines that contains both StarPoint AND EndPoint vertices, that's why I was trying ("=,=,*") = coordinate X,&amp;nbsp; = coordinate Y, * any Z coordinate.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The result of following command should be 2 polylines (RED and WHITE)&lt;/P&gt;&lt;P&gt;(setq ss1_qt (sslength ss1))&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then I remove from the ss1 the manual polyline selected using&amp;nbsp;&lt;/P&gt;&lt;P&gt;(if (ssmemb na1 ss1)&lt;BR /&gt;(ssdel na1 ss1)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The result of ss1 will be only the polyline I was looking for. (WHITE)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;(setq ss1 (ssget "_A" (list '(0 . "*POLYLINE") (cons 10 (list (car EndPoint) (car (cdr EndPoint)) 0.0 &lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The above mentioned method you will get all those PLINES&amp;nbsp;&lt;SPAN&gt;(after removing "na1")&lt;/SPAN&gt; whose Start point / End point / Any vertices passes through the two points (in your code two point are "&lt;SPAN&gt;StartPoint" &amp;amp; "EndPoint"&lt;/SPAN&gt;)......&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So to get only those&amp;nbsp;&lt;SPAN&gt;PLINES (after removing "na1") whose Either Start point or End point are&amp;nbsp;the two points (in your code two point are "StartPoint" &amp;amp; "EndPoint")..... Take each PLINE from PLINES selection set (after removing "na1") &amp;amp; check whether the&amp;nbsp;Start point or End point&amp;nbsp;is&amp;nbsp;the two points (in your code two point are "StartPoint" &amp;amp; "EndPoint") or not....&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 18 Nov 2018 15:10:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8409023#M96474</guid>
      <dc:creator>dbhunia</dc:creator>
      <dc:date>2018-11-18T15:10:49Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411224#M96475</link>
      <description>&lt;P&gt;This is the code result so far. (attached)&lt;/P&gt;&lt;P&gt;&amp;nbsp;Next step is using parts of more than one polyline to work in teste.dwg&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again!&lt;/P&gt;</description>
      <pubDate>Mon, 19 Nov 2018 18:13:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411224#M96475</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-19T18:13:40Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411636#M96476</link>
      <description>&lt;P&gt;Impressive milestone!&lt;/P&gt;
&lt;P&gt;What's your ultimate&amp;nbsp;goal? Select the entire block and all polylines inside get closed?&lt;/P&gt;</description>
      <pubDate>Mon, 19 Nov 2018 20:46:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411636#M96476</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-19T20:46:40Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411730#M96477</link>
      <description>&lt;P&gt;Hello!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The idea is to go thru all open polylines in a selected layer and then to close it using the segments of other(s) polylines.&lt;/P&gt;&lt;P&gt;I have 70 more files like teste.dwg where to use it this routine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 19 Nov 2018 21:19:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411730#M96477</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-19T21:19:40Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411937#M96478</link>
      <description>&lt;P&gt;I see. Here is this humble attempt just before bedtime, just for you&amp;nbsp;to have fun. Ain't that bad I think... might&amp;nbsp;help.&lt;/P&gt;
&lt;P&gt;Perhaps some improvements would be necessary...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;(defun c:testeclose ( / ss i obj pnt ptlst ptsum )

  (if (setq ss (ssget '((0 . "LWPOLYLINE") (-4 . "&amp;lt;NOT") (-4 . "&amp;amp;=") (70 . 1) (-4 . "NOT&amp;gt;") (-4 . "&amp;gt;") (90 . 2))))
    (repeat (setq i (sslength ss))
      (setq ptlst nil ptsum '(0 0)
	    ptlst (mapcar 'cdr (vl-remove-if-not '(lambda (x) (= (car x) 10))
				      (entget (ssname ss (setq i (1- i)))))))
      (foreach x ptlst (setq ptsum (mapcar '+ x ptsum)))
      (setq pnt (mapcar '/ ptsum (list (length ptlst) (length ptlst))))
      (if pnt (command "_.-boundary" "_non" pnt ""))))
  (princ)
)&lt;/PRE&gt;</description>
      <pubDate>Mon, 19 Nov 2018 22:46:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8411937#M96478</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-19T22:46:53Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413066#M96479</link>
      <description>&lt;P&gt;WOW! Thanks a lot!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Because I'm newbie on LIST I'll need some time to understand how do you do it and how the function works... but, is a incredible much smaller and elegant code.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is what I was thinking for solving the problem:&lt;/P&gt;
&lt;P&gt;1) To create a HATCH using PICK POINTS (centroid or something like that)&lt;BR /&gt;&amp;nbsp; &amp;nbsp; Regenerate HATCH boundaries &lt;BR /&gt;&amp;nbsp; &amp;nbsp; Erase the HATCH&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2) A more complex logic comming from the original idea&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Selecting polylines where&lt;BR /&gt;Startpoint = some coordinate of a second polyline&lt;BR /&gt;Endpoint = some coordinate of a third polyline&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;AND ALSO WHERE&lt;BR /&gt;some coordinate of second polyline and third polyline are equal&lt;BR /&gt;AND this coordinate is inside the ssget "C" from the incomplete polyline coordinates&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;- catch the coordinates of 2nd polyline between this points &lt;BR /&gt;(interrupted by equal coordinate 2nd and 3rd polyline)&lt;/P&gt;
&lt;P&gt;- catch the coordinates of 23rd polyline between this points &lt;BR /&gt;(interrupted by equal coordinate 2nd and 3rd polyline)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;- Finally using the (vla-AddVertex... complete the selected polyline (the one we want to reconstruct)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards!&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 11:11:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413066#M96479</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-20T11:11:59Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413257#M96480</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;...&amp;nbsp;Because I'm newbie on LIST I'll need some time to understand how do you do it and how the function works... but, is a incredible much smaller and elegant code.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is what I was thinking for solving the problem:&lt;/P&gt;
&lt;P&gt;1) To create a HATCH using PICK POINTS (centroid or something like that)&lt;BR /&gt;&amp;nbsp; &amp;nbsp; Regenerate HATCH boundaries &lt;BR /&gt;&amp;nbsp; &amp;nbsp; Erase the HATCH ...&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is basically what my LISP does. Only instead of doing HATCH and delete, it uses&amp;nbsp;the BOUNDARY command, which is essentially the same. Your drawing is quite good, there are no gaps. If they were I would rather use the HATCH command with its skip-gap option. This option is not available within the BOUNDARY&amp;nbsp;command.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Unfortunately, we cannot use the 'centroid&amp;nbsp;of an open polyline. But if we close them before... we can.&lt;/P&gt;
&lt;P&gt;I calculated the "average point" to get some inside point. (sum all x coords, divided&amp;nbsp;by the number&amp;nbsp;of them)&lt;/P&gt;
&lt;P&gt;= (x1+x2+...+xn)/n, the same for y.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But here are some things to you to consider to improve/change/simplify.&lt;/P&gt;
&lt;P&gt;- for each open polyline (done)&lt;/P&gt;
&lt;P&gt;- close the polyline&lt;/P&gt;
&lt;P&gt;- get its centroid point&lt;/P&gt;
&lt;P&gt;- get its layer&lt;/P&gt;
&lt;P&gt;- use the boudary command&lt;/P&gt;
&lt;P&gt;- change boundary's&amp;nbsp;layer&amp;nbsp;&lt;/P&gt;
&lt;P&gt;- remove the original polyline.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Good luck!&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 13:04:24 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413257#M96480</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-20T13:04:24Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413300#M96481</link>
      <description>&lt;P&gt;Thanks for the hints,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'ld like to put more filters in the SSGET command&lt;/P&gt;
&lt;P&gt;1) How to include in the ssget command to exclude LOCKED LAYERS? &lt;BR /&gt; I was trying "_X:L"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2) How to pick only polylines from a selected LAYER? &lt;BR /&gt; I was trying (8 . layer) but with no success. ; error: bad ssget mode string&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;3) How to select only polylines with AREA &amp;gt; 0 ??&lt;/P&gt;
&lt;P&gt;(if (setq ss (ssget "_X:L" '((0 . "LWPOLYLINE") (-4 . "&amp;lt;NOT") (-4 . "&amp;amp;=") (70 . 1) (-4 . "NOT&amp;gt;") (-4 . "&amp;gt;") (90 . 2) (8 . layer) ) ))&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I confess I do not fully understand your code yet &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt; and I still have a long path to run to reach the complete wished result.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Next step: (after cleaning up all the residual lines)&lt;BR /&gt;- to create attributes in the closest point of the polylines (lots) and the polyline (square that demarks the sidewalk and is around the lots) to indicate where is the front of the lot.&lt;BR /&gt;This will be exported to a Excel sheet where I'll have work later on...&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 13:08:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413300#M96481</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-20T13:08:49Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413375#M96482</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;...I'ld like to put more filters in the SSGET command&lt;/P&gt;
&lt;P&gt;1) How to include in the ssget command to exclude LOCKED LAYERS? &lt;BR /&gt; I was trying "_X:L"&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;It's not that simple. Look&amp;nbsp;&lt;A href="https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/combining-ssget-selection-methods-implied-not-locked/td-p/3654290" target="_blank"&gt;HERE&lt;/A&gt;&amp;nbsp;for more suggestions about this.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2) How to pick only polylines from a selected LAYER? &lt;BR /&gt; I was trying (8 . layer) but with no success. ; error: bad ssget mode string&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;You need to distinguish whether it has to be evaluated or not.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;If it's &lt;FONT color="#0000FF"&gt;a constant&lt;/FONT&gt;, the quotation is fine:&lt;FONT color="#0000FF"&gt; '&lt;/FONT&gt;((8 . &lt;FONT color="#0000FF"&gt;"Layer1"&lt;/FONT&gt;)).&amp;nbsp;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;If there is somewhere &lt;FONT color="#FF0000"&gt;a variable&lt;/FONT&gt;, then the evaluation is required. (&lt;FONT color="#FF0000"&gt;list&lt;/FONT&gt; (&lt;FONT color="#FF0000"&gt;cons&lt;/FONT&gt; 8 &lt;FONT color="#FF0000"&gt;layer&lt;/FONT&gt;)) or (&lt;FONT color="#FF0000"&gt;list&lt;/FONT&gt;&lt;FONT color="#0000FF"&gt; '&lt;/FONT&gt;(0 . "&lt;FONT color="#0000FF"&gt;LINE&lt;/FONT&gt;") (&lt;FONT color="#FF0000"&gt;cons&lt;/FONT&gt; 8 &lt;FONT color="#FF0000"&gt;layer&lt;/FONT&gt;))&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;3) How to select only polylines with AREA &amp;gt; 0 ??&lt;/P&gt;
&lt;P&gt;(if (setq ss (ssget "_X:L" '((0 . "LWPOLYLINE") (-4 . "&amp;lt;NOT") (-4 . "&amp;amp;=") (70 . 1) (-4 . "NOT&amp;gt;") (-4 . "&amp;gt;") (90 . 2) (8 . layer) ) ))&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;No way.&amp;nbsp;You can only use filter of properties stored in a definition list of entity. You need to go thru the ss...&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I confess I do not fully understand your code yet &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt; and I still have a long path to run to reach the complete wished result.&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;Hightlight the parts you have issues with and I'll try to explain it&amp;nbsp; in words.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Next step: (after cleaning up all the residual lines)&lt;BR /&gt;- to create attributes in the closest point of the polylines (lots) and the polyline (square that demarks the sidewalk and is around the lots) to indicate where is the front of the lot.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#000000"&gt;You will need to ilustrate that on dwg.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 13:59:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413375#M96482</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-20T13:59:19Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413580#M96483</link>
      <description>&lt;P&gt;My main doubt is:&lt;/P&gt;
&lt;P&gt;- boundary parameters list - (command "_.-boundary" "_non" pnt "") - ?WHERE TO FIND?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Attached is the DWG to ilustrate next step. The attributes will be created and put inside the objects using AUTOCAD CIVIL.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For the 123 SSGET questions I'll am working on it, later on I'll put the code here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks again.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 14:32:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413580#M96483</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-20T14:32:20Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413606#M96484</link>
      <description>&lt;P&gt;What do you mean by "&lt;SPAN style="font-family: inherit;"&gt;Where to find?" Where &lt;STRONG&gt;&lt;EM&gt;what&lt;/EM&gt; &lt;/STRONG&gt;to find? &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;Syntax? I guess you do understand the syntax of this short line... or do you?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;Point? You don't understand how the pnt&amp;nbsp;is supplied/calculated? &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;?? Or something else?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 14:39:39 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413606#M96484</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-20T14:39:39Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413911#M96485</link>
      <description>&lt;P&gt;I've seen your dwg...&lt;/P&gt;
&lt;P&gt;Not sure about your "skip-gap" needed. You mean like there is the entire front line of 9,4 m length missing which you need to skip? If so, that would be too much for the HATCH command.&lt;/P&gt;
&lt;P&gt;In general, I doubt that you'll be able to solve all the map's issues&amp;nbsp;automatically. Maybe 99,9%, but the rest would be so unique, that would not worth the spent&amp;nbsp;time. I'm afraid that the last manual check would be necessary.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 16:12:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8413911#M96485</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-20T16:12:27Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8414270#M96486</link>
      <description>&lt;P&gt;- I did manage to include layer filter in the SSGET command.&lt;/P&gt;
&lt;P&gt;- AREA was handled inside the ss loop.&lt;/P&gt;
&lt;P&gt;- Polyline Boundary was created in a selected layer&lt;/P&gt;
&lt;P&gt;- Old and opened polylines were moved to a layer to be later on deleted.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It was a beautiful thing to see... automaticly closing 400 polyline at least. The updated code is attached.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Somethings to do automactlly I hope:&lt;BR /&gt;- delete duplicate polylines&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But probably manually&lt;BR /&gt;- to compare the drawings&lt;BR /&gt;- fine adjustments&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;After that I am going to the next steps.&lt;/P&gt;
&lt;P&gt;Thanks a lot!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;P.S.: About the boundary command: Forget about it.&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 18:56:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8414270#M96486</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-20T18:56:13Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8414282#M96487</link>
      <description>&lt;P&gt;Handling area property is definitely go this, just the commentary amused&amp;nbsp;me.&lt;/P&gt;
&lt;P&gt;Do you know what the blue part is for? &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;(setq ss (ssget "_X" (list ...... (cons 70 1) (cons -4 "NOT&amp;gt;") &lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;(cons -4 "&amp;gt;") (cons 90 2)&lt;/FONT&gt;&lt;/STRONG&gt;) ))&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;....&amp;nbsp;It was a beautiful thing to see... automaticly closing 400 polyline at least. ....&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yeah, I'm sure of it! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You &lt;FONT color="#FF0000"&gt;need to merge&lt;STRONG&gt; j&lt;/STRONG&gt; and &lt;/FONT&gt;i into &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;one&lt;/STRONG&gt;&lt;/FONT&gt;!!! Both do the same thing but the later goes&amp;nbsp;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;the other way around&lt;/STRONG&gt;&lt;/FONT&gt; than the first one!!!&lt;/P&gt;
&lt;P&gt;j goes from max to 0, i from 0 to max!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 19:18:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8414282#M96487</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-20T19:18:38Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8414668#M96488</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Do you know what the blue part is for? &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;NOPE&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Nov 2018 21:39:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8414668#M96488</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-11-20T21:39:28Z</dc:date>
    </item>
    <item>
      <title>Re: SSGET to select a polyline using two coordinates as filters</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8415767#M96489</link>
      <description>&lt;P&gt;Let's find out then!&lt;/P&gt;
&lt;P&gt;Look into help&amp;nbsp;&lt;A href="http://help.autodesk.com/view/ACD/2018/ENU/?guid=GUID-748FC305-F3F2-4F74-825A-61F04D757A50" target="_blank"&gt;HERE&lt;/A&gt;&amp;nbsp;for "dxf&amp;nbsp;lwpolyline"&amp;nbsp;to see what 90 code represents.&lt;/P&gt;
&lt;P&gt;Then explore the SSGET filters possibilities&amp;nbsp;&lt;A href="http://help.autodesk.com/view/ACD/2018/ENU/?guid=GUID-7BE77062-C359-4D01-915B-69CF672C653B" target="_blank"&gt;HERE&lt;/A&gt;&amp;nbsp;(see the entire tree branch), especially then the relation&amp;nbsp;tests&amp;nbsp;&lt;A href="http://help.autodesk.com/view/ACD/2018/ENU/?guid=GUID-877CEEA5-0D88-48DF-8450-B9421031A1B7" target="_blank"&gt;HERE&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Nov 2018 09:39:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/ssget-to-select-a-polyline-using-two-coordinates-as-filters/m-p/8415767#M96489</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2018-11-21T09:39:25Z</dc:date>
    </item>
  </channel>
</rss>

