<?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: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp;amp; Polygons from Poi in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301335#M23422</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Fabian, Thanks for your nice response.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This morning, I re-typed the Sample Code of creating "polygons" in the Python Window of my ArcGIS 10.0:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;gt;&amp;gt;&amp;gt; import arcpy
&amp;gt;&amp;gt;&amp;gt; coordList = [[[1.2], [2,4], [3,7]],
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [[6,8], [5,7], [7,2], [9,5]]]
... point = arcpy.Point()
... array = arcpy.Array()
... featureList = []
... for feature in coordList:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for coordPair in feature:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.X = coordPair[0]
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.Y = coordPair[1]
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.add(point)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.add(array.getObject(0))
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; polygon = arcpy.Polygon(array)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.removeAll()
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureList.apend(polygon)
... arcpy.CopyFeatures_management(featureList, "c:/TEMP/PythonWindow10_0/polygons.shp"
... 
Parsing error &amp;lt;type 'exceptions.SyntaxError'&amp;gt;: invalid syntax (line 17)
&amp;gt;&amp;gt;&amp;gt; &lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I forgot to put �??)�?� in the end of the last code statement and I got a syntax error.&amp;nbsp; It is time consuming and error prone, if I re-type the Python/ArcPy codes from the beginning of my Python-ArcPy script.&amp;nbsp; I did Google search and I did not get much out from the Google search about writing a scripttool for a toolbox (without parameter)!!! Two questions to ask you: (1) Is any easy way to correct a syntax error of ArcPy-Python in Python Window directly? (2) How can I write a scripttool for a toolbox (without parameter)?&amp;nbsp; Please kindly help, advise and respond again.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Many Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Scott Chang&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 11 Dec 2021 14:27:35 GMT</pubDate>
    <dc:creator>ScottChang</dc:creator>
    <dc:date>2021-12-11T14:27:35Z</dc:date>
    <item>
      <title>ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp;amp; Polygons from Points</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301328#M23415</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi all,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;1) This morning, in the Python Window of my ArcGIS 10.0, I played with the ArcPy Class "Point" and got the following 2 points:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;&amp;gt;&amp;gt;&amp;gt; import arcpy
&amp;gt;&amp;gt;&amp;gt; pointA = arcpy.Point(2.0, 4.5)
&amp;gt;&amp;gt;&amp;gt; pointB = arcpy.Point(3.0, 7.0)
&amp;gt;&amp;gt;&amp;gt; print pointA
2 4.5 NaN NaN

&amp;gt;&amp;gt;&amp;gt; print pointB
3 7 NaN NaN

&amp;gt;&amp;gt;&amp;gt; &lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(i)&amp;nbsp; What is the "NaN" in the results of the "print" Command?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(ii)&amp;nbsp; If I want to use the "World" Geographic system for the X,Y-coordinates, how can I specify it?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;2) If I want to use these 2 points to make a Polyline, how can I use the Python programming to connect these 2 points to form a Polyline?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; If I add a more point {poinC = arcpy.Point(0,0)}, how can I use the Python programming to form a Triangle from these 3 points?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Please kindly help, give me the ArcPy commands/Python tools to create Polylines and Polygons from Points, and respond.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Scott Chang&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2012 12:49:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301328#M23415</guid>
      <dc:creator>ScottChang</dc:creator>
      <dc:date>2012-09-06T12:49:34Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301329#M23416</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;NaN is reference to something that is 'Not a Number'... why its appearing in that Print statement i'm not sure though, since a 'point' is conceptually not a number, perhaps that is not surprising.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Take a look at this help about Arrays in arcpy - the code sample at the end shows how to create a polyline from a collection of points.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/main/10.1/index.html#/Array/018z0000006n000000/"&gt;http://resources.arcgis.com/en/help/main/10.1/index.html#/Array/018z0000006n000000/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Good luck!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2012 13:07:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301329#M23416</guid>
      <dc:creator>ChristopherThompson</dc:creator>
      <dc:date>2012-09-06T13:07:27Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301330#M23417</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The NaN values are there are placeholders for z and m values. Essentially it is a null.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2012 13:25:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301330#M23417</guid>
      <dc:creator>MathewCoyle</dc:creator>
      <dc:date>2012-09-06T13:25:36Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301331#M23418</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This will help:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Reading geometries:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002z0000001t000000"&gt;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002z0000001t000000&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;Writing geometries:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002z0000001v000000"&gt;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002z0000001v000000&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2012 13:31:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301331#M23418</guid>
      <dc:creator>FabianBlau</dc:creator>
      <dc:date>2012-09-06T13:31:00Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301332#M23419</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Christopher, Mathew and Fabian, Thanks for your nice responses.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I stydied the materials of Array, Polyline, Polygon, etc. of ArcPy Classes from the HELP of ArcGIS 10.0. In the Python Window of my ArcGIS 10.0, I executed the Code Samples of Array, Polyline and Polygon, and used "arcpy.CopyFeatures_management(inFC,outFC)" to bring the "polylines" shapefile to the mxd Map.&amp;nbsp; I got my "Polyline" project OK.&amp;nbsp; But I got an error in my "Polygon" project, when I tried to run the Code Sample of Polygon - see the following:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;gt;&amp;gt;&amp;gt; coordList = [[[1,2], [2,4], [3,7]],
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [[6,8], [5,7], [7,2], [9,5]]]
...&amp;nbsp; 
... 
&amp;gt;&amp;gt;&amp;gt; point = arcpy.Point()
&amp;gt;&amp;gt;&amp;gt; array = arcpy.Array()
&amp;gt;&amp;gt;&amp;gt; featureList = []
&amp;gt;&amp;gt;&amp;gt; for feature in coordList:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for coordPair in feature:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.X = coordPair[0]
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.Y = coordPair[1]
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.add(point)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; polyline = arcpy.Polyline(array)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.removeAll()
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureList.append(polyline)
... arcpy.CopyFeatures_management(featureList, "c:/TEMP/PythonWindow10_0/polylines.shp")
... 
&amp;gt;&amp;gt;&amp;gt; arcpy.env.workspace=r'c:\TEMP\PythonWindow10_0'
&amp;gt;&amp;gt;&amp;gt; inFC='polylines.shp'
&amp;gt;&amp;gt;&amp;gt; outFC='polylinesArcPy.shp'
&amp;gt;&amp;gt;&amp;gt; arcpy.CopyFeatures_management(inFC,outFC)
&amp;lt;Result 'c:\\TEMP\\PythonWindow10_0\\polylinesArcPy.shp'&amp;gt;
&amp;gt;&amp;gt;&amp;gt; # To create polygon by using the existing points
&amp;gt;&amp;gt;&amp;gt; for feature in coordList:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for coordPair in feature:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.X = coordPair(0)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.Y = coordPair(1)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.add(point)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.add(array.getObject(0))
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; polygon = array.Polygon(array)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.removeAll()
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureList.append(polygon)
... arcpy.CopyFeatures_management(featureList, "c:/TEMP/PythonWindow10_0/polygons.shp")
... 
Runtime error &amp;lt;type 'exceptions.TypeError'&amp;gt;: 'list' object is not callable
&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;I have no ideas where I made the mistake in the "Polygon" Python scritpt.&amp;nbsp; Please kindly help and tell me how I can correct this problem.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Scott Chang&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;P. S. I don't know how to re-use/copy the good Python-ArcPy code statements in the Python Window.&amp;nbsp; It is too time consuming to type the good Python-ArcPy code statements.&amp;nbsp; Please advise on this matter.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 14:27:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301332#M23419</guid>
      <dc:creator>ScottChang</dc:creator>
      <dc:date>2021-12-11T14:27:30Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301333#M23420</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Polygons require at minimum 4 points to create a triangle. The start and end points must be coincident to close the polygon. The polygon object won't "jump" from the last point to the first point to close itself.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Edit: Ignore the above, I see you did that already. Seems like you are adding both polyline and polygon features to the same feature list and trying to copy them out at the same time. That seems to be the most likely issue. If you need to export both the polyline and polygon features you will need two separate copy feature calls.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Sep 2012 18:37:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301333#M23420</guid>
      <dc:creator>MathewCoyle</dc:creator>
      <dc:date>2012-09-06T18:37:58Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301334#M23421</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;#1&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Little Error in the second loop:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.X = coordPair(0)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.Y = coordPair(1)
&lt;/PRE&gt;&lt;BR /&gt;&lt;SPAN&gt;Use:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.X = coordPair[0]
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.Y = coordPair[1]
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;#2&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;write a scripttool for a toolbox. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;You do not need any parameters, if you change them in the script.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It is not that much work.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 14:27:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301334#M23421</guid>
      <dc:creator>FabianBlau</dc:creator>
      <dc:date>2021-12-11T14:27:33Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301335#M23422</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Fabian, Thanks for your nice response.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This morning, I re-typed the Sample Code of creating "polygons" in the Python Window of my ArcGIS 10.0:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;gt;&amp;gt;&amp;gt; import arcpy
&amp;gt;&amp;gt;&amp;gt; coordList = [[[1.2], [2,4], [3,7]],
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [[6,8], [5,7], [7,2], [9,5]]]
... point = arcpy.Point()
... array = arcpy.Array()
... featureList = []
... for feature in coordList:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for coordPair in feature:
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.X = coordPair[0]
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; point.Y = coordPair[1]
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.add(point)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.add(array.getObject(0))
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; polygon = arcpy.Polygon(array)
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array.removeAll()
...&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureList.apend(polygon)
... arcpy.CopyFeatures_management(featureList, "c:/TEMP/PythonWindow10_0/polygons.shp"
... 
Parsing error &amp;lt;type 'exceptions.SyntaxError'&amp;gt;: invalid syntax (line 17)
&amp;gt;&amp;gt;&amp;gt; &lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I forgot to put �??)�?� in the end of the last code statement and I got a syntax error.&amp;nbsp; It is time consuming and error prone, if I re-type the Python/ArcPy codes from the beginning of my Python-ArcPy script.&amp;nbsp; I did Google search and I did not get much out from the Google search about writing a scripttool for a toolbox (without parameter)!!! Two questions to ask you: (1) Is any easy way to correct a syntax error of ArcPy-Python in Python Window directly? (2) How can I write a scripttool for a toolbox (without parameter)?&amp;nbsp; Please kindly help, advise and respond again.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Many Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Scott Chang&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 14:27:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301335#M23422</guid>
      <dc:creator>ScottChang</dc:creator>
      <dc:date>2021-12-11T14:27:35Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS 10.0:Using ArcPy classes in Python to create Polylines &amp; Polygons from Poi</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301336#M23423</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You spelled append wrong&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Nov 2014 01:02:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-10-0-using-arcpy-classes-in-python-to/m-p/301336#M23423</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2014-11-10T01:02:47Z</dc:date>
    </item>
  </channel>
</rss>

