<?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: Syntax to retrieve x/y coordinates in python? in Geoprocessing Questions</title>
    <link>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385562#M13136</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks a bunch!&amp;nbsp; that got me on the right track.&amp;nbsp; Although, sadly, I thought I'd be getting back a lat/long values as the x/y.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm starting with a shapefile of nad/stateplane, project it to geographic, and want to then extract all the lat/long values (all within the script).&amp;nbsp; *sigh*&amp;nbsp; back to google...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;edit: nevermind, it works, I forgot to uncomment the projection command, lol.&amp;nbsp; here is some code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;rows = gp.UpdateCursor(proj_shp)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;row = rows.Next()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;while row:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; feat = row.shape&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; pnt = feat.GetPart(0)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; print "x: " + str( pnt.x )&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 22 Sep 2010 20:59:36 GMT</pubDate>
    <dc:creator>ThomasMeyer</dc:creator>
    <dc:date>2010-09-22T20:59:36Z</dc:date>
    <item>
      <title>Syntax to retrieve x/y coordinates in python?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385560#M13134</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm opening a point shapefile cursor, while row: ...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;shouldn't it be something like:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;row.shape.x&amp;nbsp; ??&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've tried for many hours looking for this answer online to no avail.&amp;nbsp; Is there no api?&amp;nbsp;&amp;nbsp; I don't see Shape 'class' on the "Geoprocess Object Model", what am I missing?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Sep 2010 19:49:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385560#M13134</guid>
      <dc:creator>ThomasMeyer</dc:creator>
      <dc:date>2010-09-22T19:49:07Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax to retrieve x/y coordinates in python?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385561#M13135</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Take a look at:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/Reading_geometries/002z0000001t000000/"&gt;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/Reading_geometries/002z0000001t000000/&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Sep 2010 19:55:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385561#M13135</guid>
      <dc:creator>LanceShipman</dc:creator>
      <dc:date>2010-09-22T19:55:13Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax to retrieve x/y coordinates in python?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385562#M13136</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks a bunch!&amp;nbsp; that got me on the right track.&amp;nbsp; Although, sadly, I thought I'd be getting back a lat/long values as the x/y.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm starting with a shapefile of nad/stateplane, project it to geographic, and want to then extract all the lat/long values (all within the script).&amp;nbsp; *sigh*&amp;nbsp; back to google...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;edit: nevermind, it works, I forgot to uncomment the projection command, lol.&amp;nbsp; here is some code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;rows = gp.UpdateCursor(proj_shp)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;row = rows.Next()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;while row:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; feat = row.shape&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; pnt = feat.GetPart(0)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; print "x: " + str( pnt.x )&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Sep 2010 20:59:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385562#M13136</guid>
      <dc:creator>ThomasMeyer</dc:creator>
      <dc:date>2010-09-22T20:59:36Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax to retrieve x/y coordinates in python?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385563#M13137</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;If they are points, just calculate xy values by calling the ArcToolbox tool, and populate the attribute table with lat/long.&amp;nbsp; Then use a search cursor to extract the lat long for each point.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Sep 2010 17:42:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385563#M13137</guid>
      <dc:creator>GerryGabrisch</dc:creator>
      <dc:date>2010-09-23T17:42:08Z</dc:date>
    </item>
    <item>
      <title>Re: Syntax to retrieve x/y coordinates in python?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385564#M13138</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;If they are points, just calculate xy values by calling the ArcToolbox tool, and populate the attribute table with lat/long.&amp;nbsp; Then use a search cursor to extract the lat long for each point.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Sorry, what I meant to say was reproject the data into WGS84 and use the AddXY Coordinates tool to populate the attribute table with lats/longs, then use the cursor to step through the records.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Feb 2012 17:01:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/syntax-to-retrieve-x-y-coordinates-in-python/m-p/385564#M13138</guid>
      <dc:creator>GerryGabrisch</dc:creator>
      <dc:date>2012-02-23T17:01:15Z</dc:date>
    </item>
  </channel>
</rss>

