<?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: Issues with ArcPy SpatialReference Class in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352596#M27633</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: arial, helvetica, 'helvetica neue', verdana, sans-serif;"&gt;It's very odd. I am not sure as to why the UTM ids don't work if the SpatialReferece object is assigned their name rather than their WKID. I was hoping to avoid creating a dictionary in Python for the UTM zones and their respective WKID numbers. I wasn't sure that they were sequential, but that will work.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 27 Apr 2016 16:27:06 GMT</pubDate>
    <dc:creator>MattBrehm</dc:creator>
    <dc:date>2016-04-27T16:27:06Z</dc:date>
    <item>
      <title>Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352588#M27625</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I am attempting to write a Python script that uses a general reference map of the NAD 1983 UTM Zones to automate the selection of an appropriate map projection for a specific area. I have completed the script up until the point at which I need to create a SpatialReference object that contains the appropriate projection. I have been getting a 999999 general runtime error whenever I try to assign the SpatialReference object the value of "NAD 1983 UTM Zone 9N" or lower, but past "NAD 1983 UTM Zone 10N", it works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="196305" class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/196305_pastedImage_5.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; This screenshot is the result of a test script in which I import ArcPy, and then try to initialize a SpatialReference object with the respective values mentioned above. In the second run, I printed the SpatialReference object's name in order to test to make sure that the value was assigned correctly. Am I missing something here, or is this a known issue with assigning the names of projections to SpatialReference objects? I would otherwise use the WKID for the projection, but the reference map that I am using only contains a field for the name of the projection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit: I am using general reference maps for both the NAD 1983 UTM Zones as well as the USA State Plane Zones NAD83 in order to find an appropriate projection for an input dataset. I first find the centroid of the dataset, and then select by location from the reference projection maps. From the responses here and my own testing, it seems as if trying to assign SpatialReference objects the projections by name does not work for certain types of projections. Namely, the NAD 1983 UTM Zone 1-9 projections. I have also yet to find a U.S. State Plane projection in which the SpatialReference object does not give an error when attempting to assign the projection by name. The solution seems to be to assign the SpatialReference object by WKID. but this could be quite cumbersome if the assignment of projection WKIDs does not follow an intuitive pattern and you're working with hundreds of reference projections.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 08:34:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352588#M27625</guid>
      <dc:creator>MattBrehm</dc:creator>
      <dc:date>2016-04-27T08:34:15Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352589#M27626</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a vague recollection of something... try putting an r in front of the coordinate reference ie r"NAD....." but I remember something about underscores, but I can't put my hands on it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 09:27:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352589#M27626</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2016-04-27T09:27:44Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352590#M27627</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Why not just use the WKID to reference the correct zone.&lt;/P&gt;&lt;P&gt;NAD83 UTM xxN is numbered very logically&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NAD_1983_UTM_Zone_1N 26901&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NAD_1983_UTM_Zone_2N 26902&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NAD_1983_UTM_Zone_10N 26910&lt;/P&gt;&lt;P&gt;etc&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 09:57:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352590#M27627</guid>
      <dc:creator>NeilAyres</dc:creator>
      <dc:date>2016-04-27T09:57:31Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352591#M27628</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;his last sentence says why&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 10:04:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352591#M27628</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2016-04-27T10:04:23Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352592#M27629</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You could just create it on the fly.&lt;/P&gt;&lt;P&gt;A quick investigation...&lt;/P&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; idList = [str(i+1).zfill(2) for i in range(0, 50)]
&amp;gt;&amp;gt;&amp;gt; idList
['01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31', '32', '33', '34', '35', '36', '37', '38', '39', '40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '50']
&amp;gt;&amp;gt;&amp;gt; base = "269"
&amp;gt;&amp;gt;&amp;gt; for i in idList:
 sr = arcpy.SpatialReference(int(base + i))
 name = sr.name
 print "WKID {}&amp;nbsp; Name {}".format(int(base + i), name)

WKID 26901&amp;nbsp; Name NAD_1983_UTM_Zone_1N
WKID 26902&amp;nbsp; Name NAD_1983_UTM_Zone_2N
WKID 26903&amp;nbsp; Name NAD_1983_UTM_Zone_3N
WKID 26904&amp;nbsp; Name NAD_1983_UTM_Zone_4N
WKID 26905&amp;nbsp; Name NAD_1983_UTM_Zone_5N
WKID 26906&amp;nbsp; Name NAD_1983_UTM_Zone_6N
WKID 26907&amp;nbsp; Name NAD_1983_UTM_Zone_7N
WKID 26908&amp;nbsp; Name NAD_1983_UTM_Zone_8N
WKID 26909&amp;nbsp; Name NAD_1983_UTM_Zone_9N
WKID 26910&amp;nbsp; Name NAD_1983_UTM_Zone_10N
WKID 26911&amp;nbsp; Name NAD_1983_UTM_Zone_11N
WKID 26912&amp;nbsp; Name NAD_1983_UTM_Zone_12N
WKID 26913&amp;nbsp; Name NAD_1983_UTM_Zone_13N
WKID 26914&amp;nbsp; Name NAD_1983_UTM_Zone_14N
WKID 26915&amp;nbsp; Name NAD_1983_UTM_Zone_15N
WKID 26916&amp;nbsp; Name NAD_1983_UTM_Zone_16N
WKID 26917&amp;nbsp; Name NAD_1983_UTM_Zone_17N
WKID 26918&amp;nbsp; Name NAD_1983_UTM_Zone_18N
WKID 26919&amp;nbsp; Name NAD_1983_UTM_Zone_19N
WKID 26920&amp;nbsp; Name NAD_1983_UTM_Zone_20N
WKID 26921&amp;nbsp; Name NAD_1983_UTM_Zone_21N
WKID 26922&amp;nbsp; Name NAD_1983_UTM_Zone_22N
WKID 26923&amp;nbsp; Name NAD_1983_UTM_Zone_23N&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It errors out after 23.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 16:33:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352592#M27629</guid>
      <dc:creator>NeilAyres</dc:creator>
      <dc:date>2021-12-11T16:33:00Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352593#M27630</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This name vs wkid to specify the sr is very odd.&lt;/P&gt;&lt;P&gt;This wkid from my help files.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;sr = arcpy.SpatialReference(102007)
&amp;gt;&amp;gt;&amp;gt; sr.name
u'Hawaii_Albers_Equal_Area_Conic'
&amp;gt;&amp;gt;&amp;gt; sr = arcpy.SpatialReference('Hawaii_Albers_Equal_Area_Conic')
Traceback (most recent call last): # errors out here, but then replace the "_" with a space
&amp;nbsp; File "&amp;lt;pyshell#23&amp;gt;", line 1, in &amp;lt;module&amp;gt;&lt;/PRE&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;sr = arcpy.SpatialReference('Hawaii_Albers_Equal_Area_Conic'.replace("_", " "))
&amp;gt;&amp;gt;&amp;gt; sr
&amp;lt;SpatialReference object at 0x2a68850[0x1108ead0]&amp;gt;
&amp;gt;&amp;gt;&amp;gt; sr.name
u'Hawaii_Albers_Equal_Area_Conic'&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 16:33:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352593#M27630</guid>
      <dc:creator>NeilAyres</dc:creator>
      <dc:date>2021-12-11T16:33:03Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352594#M27631</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;But that approach doesn't work with these UTM ids.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;gt;&amp;gt;&amp;gt; sr = arcpy.SpatialReference(26901)
&amp;gt;&amp;gt;&amp;gt; sr.name
u'NAD_1983_UTM_Zone_1N'
&amp;gt;&amp;gt;&amp;gt; sr = arcpy.SpatialReference('NAD_1983_UTM_Zone_1N'.replace("_", " "))
Traceback (most recent call last):
&amp;nbsp; File "&amp;lt;pyshell#29&amp;gt;", line 1, in &amp;lt;module&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; sr = arcpy.SpatialReference('NAD_1983_UTM_Zone_1N'.replace("_", " "))
&amp;nbsp; File "C:\Program Files (x86)\ArcGIS\Desktop10.3\ArcPy\arcpy\arcobjects\mixins.py", line 949, in __init__
&amp;nbsp;&amp;nbsp;&amp;nbsp; self._arc_object.createFromFile(item)
RuntimeError: ERROR 999999: Error executing function.
&amp;gt;&amp;gt;&amp;gt; &lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 16:33:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352594#M27631</guid>
      <dc:creator>NeilAyres</dc:creator>
      <dc:date>2021-12-11T16:33:05Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352595#M27632</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I did try this, I know that putting an 'r' in front of a string indicates to Python to read the string as a literal, rather than reading in special characters.&lt;/P&gt;&lt;P&gt;i.e. Writing a string with "\n" in it will tell Python to print to the next line, etc.&lt;/P&gt;&lt;P&gt;I also ran a few tests with underscores vs. spaces&lt;/P&gt;&lt;P&gt;But unfortunately, it did not solve the issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 16:25:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352595#M27632</guid>
      <dc:creator>MattBrehm</dc:creator>
      <dc:date>2016-04-27T16:25:32Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352596#M27633</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: arial, helvetica, 'helvetica neue', verdana, sans-serif;"&gt;It's very odd. I am not sure as to why the UTM ids don't work if the SpatialReferece object is assigned their name rather than their WKID. I was hoping to avoid creating a dictionary in Python for the UTM zones and their respective WKID numbers. I wasn't sure that they were sequential, but that will work.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 16:27:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352596#M27633</guid>
      <dc:creator>MattBrehm</dc:creator>
      <dc:date>2016-04-27T16:27:06Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352597#M27634</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It also seems to work with UTM Zones greater than 10. If you were to run your test again with the NAD 1983 UTM Zone 10N projection, it should work correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Such as:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/196348_pastedImage_0.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;P&gt;vs.&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-2 jive-image" src="https://community.esri.com/legacyfs/online/196352_pastedImage_1.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 16:39:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352597#M27634</guid>
      <dc:creator>MattBrehm</dc:creator>
      <dc:date>2016-04-27T16:39:14Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352598#M27635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Matt,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;From my experience of working with the SpatialReference class in Python, there are issues that have not been addressed. Certain properties that are SUPPOSED to be Read/Write are actually Read only. I had to go a complete back door approach in order to create my .prj file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is what I had to do:&lt;/P&gt;&lt;PRE __default_attr="python" __jive_macro_name="code" class="jive_macro_code jive_text_macro _jivemacro_uid_14617753108117837" data-renderedposition="163.1107940673828_7.997159004211426_1332_69" jivemacro_uid="_14617753108117837"&gt;&lt;OL class="dp-py" start="1" style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #5c5c5c; margin-bottom: 1px !important; margin-left: 45px !important;"&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt;prj = open(r&lt;/SPAN&gt;&lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;"C:\junk\my_new_prj_file.prj"&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt;, &lt;/SPAN&gt;&lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;"w"&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt;)&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;crs_string = &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'PROJCS["NAD_1983_UTM_Zone_10N",GEOGCS["GCS_North_American_1983",DATUM["D_North_American_1983",SPHEROID["GRS_1980",6378137,298.257222101]],PRIMEM["Greenwich",0],UNIT["Degree",0.017453292519943295]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-123],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["Meter",1]]'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;prj.write(crs_string)&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;prj.close() &lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 16:42:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352598#M27635</guid>
      <dc:creator>AdrianWelsh</dc:creator>
      <dc:date>2016-04-27T16:42:34Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352599#M27636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Matt,&lt;/P&gt;&lt;P&gt;yes this sr.name vs the "Name" you're supposed to use when trying to initiate it seems to be a bit inconsistent.&lt;/P&gt;&lt;P&gt;The help files refers to the pdf in the documentation installation area. But those "Names" all have underscores.&lt;/P&gt;&lt;P&gt;Perhaps Melita or an esri guru could explain.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 18:05:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352599#M27636</guid>
      <dc:creator>NeilAyres</dc:creator>
      <dc:date>2016-04-27T18:05:46Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352600#M27637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not to be insulting, but that seems like a major pain lol. It is helpful in that it shows what would go into defining the .prj file, but for just the StatePlane projections in the U.S. alone, there are 121 different features. I would not want to have to do this for all of them. I was hoping for an easy solution, but it seems as if adding a WKID field to the attribute table of the reference projection maps, adding the WKIDs for each of the projection systems, and referencing them with a SearchCursor in ArcPy is the best option for this type of workflow.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 20:47:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352600#M27637</guid>
      <dc:creator>MattBrehm</dc:creator>
      <dc:date>2016-04-27T20:47:27Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352601#M27638</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Matt... moved to &lt;A href="https://community.esri.com/space/2145"&gt;Python&lt;/A&gt;​ and shared with &lt;A href="https://community.esri.com/group/1386"&gt;Coordinate Reference Systems&lt;/A&gt;​ and flagging &lt;A href="https://community.esri.com/migrated-users/3120"&gt;Melita Kennedy&lt;/A&gt;​ to see if a solution or commentary can be found&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Apr 2016 21:41:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352601#M27638</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2016-04-27T21:41:07Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352602#M27639</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not insulting here! It's just that this is the ONLY thing that would work for me due to me needing to creating CUSTOM projection files. If I could have used out-of-the-box projections, then utilizing the WKID would have been ideal. But, you're right, it is a major pain!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have it more "programmatic" than just a giant string of text, though. Each of the changing variables in that string (like units, projection, scale factor, etc.) is a variable that I created earlier in the script that programmatically accesses user input so then the string looks more like this:&lt;/P&gt;&lt;PRE __default_attr="python" __jive_macro_name="code" class="jive_macro_code jive_text_macro _jivemacro_uid_14618486235279505" data-renderedposition="137.65625_7.997159004211426_1332_195" jivemacro_uid="_14618486235279505"&gt;&lt;OL class="dp-py" start="1" style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #5c5c5c; margin-bottom: 1px !important; margin-left: 45px !important;"&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt; projString = (&lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'PROJCS["' + str(PIN) + '_'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + ProjName +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'",GEOGCS['&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + GeoCS +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],PROJECTION["'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + ProjectionName +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'"],PARAMETER["False_Easting",'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + str(FalseEasting) +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],PARAMETER["False_Northing",'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + str(FalseNorthing) +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],PARAMETER["Central_Meridian",'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + str(CentralMeridian) +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],PARAMETER["Standard_Parallel_1",'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + str(StandardParallel1) +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],PARAMETER["Standard_Parallel_2",'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + str(StandardParallel2) +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],PARAMETER["Scale_Factor",'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + str(ScaleFactor) +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],PARAMETER["Latitude_Of_Origin",'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt; + str(LatOfOrigin) +&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; color: black; font-size: 9pt !important; background-color: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="string" style="font-weight: inherit; font-style: inherit; color: blue; font-size: 9pt !important; background-color: inherit;"&gt;'],UNIT["' + LinearUnit + '",' + str(MetersPerFoot) + ']]'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 9pt !important; background-color: inherit;"&gt;) &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But, then again, this works for me and may not be the best choice for your dataset.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Apr 2016 13:04:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352602#M27639</guid>
      <dc:creator>AdrianWelsh</dc:creator>
      <dc:date>2016-04-28T13:04:01Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352603#M27640</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;And the answer is...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;there should be two spaces between Zone and 9N. That's true of most of the NAD-based UTM zones. The name look-up that arcpy is performing isn't on the object's internal name ("NAD_1983_UTM_Zone_9N"), but on the name used for the coordinate systems "folder" structure. At the time I set them up, I didn't know that we planned to add a name look-up using them. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Melita&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Apr 2016 16:29:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352603#M27640</guid>
      <dc:creator>MelitaKennedy</dc:creator>
      <dc:date>2016-04-28T16:29:09Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352604#M27641</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;/PRE&gt;&lt;P&gt;I have a related question to spatial references.&lt;BR /&gt;I usually reference the incoming feature class or use the specific factory code for a projection.&lt;/P&gt;&lt;P&gt;Examples:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
OutPut = arcpy.CreateFeatureclass_management(workspace, tempOutName, "POLYLINE", template=inFeatureClass,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; spatial_reference=inFeatureClass)

&lt;SPAN style="color: #333333; font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; font-size: 12px;"&gt;# or&lt;/SPAN&gt;

&lt;SPAN style="color: #333333; font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; font-size: 12px;"&gt;webMercatorAux &lt;/SPAN&gt;&lt;SPAN class="pl-k" style="color: #a71d5d; font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; font-size: 12px;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #333333; font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; font-size: 12px;"&gt; arcpy.SpatialReference(&lt;/SPAN&gt;&lt;SPAN class="pl-c1" style="color: #0086b3; font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; font-size: 12px;"&gt;3857&lt;/SPAN&gt;&lt;SPAN style="color: #333333; font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; font-size: 12px;"&gt;)
&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was curious while reading this you could use either of these approaches?&amp;nbsp; Is there a stability advantage? (One of my projects has some cursor instability issues ATM and I am not sure what is causing it). &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 16:33:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352604#M27641</guid>
      <dc:creator>DavidWasserman</dc:creator>
      <dc:date>2021-12-11T16:33:08Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352605#M27642</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;David, I would think that either method should work fine. I personally prefer to reference in the spatial reference from an existing feature class just so I know it will keep things in the same system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What instability issues are you seeing? Are you getting error messages? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Apr 2016 16:59:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352605#M27642</guid>
      <dc:creator>AdrianWelsh</dc:creator>
      <dc:date>2016-04-28T16:59:55Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352606#M27643</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey Adrian, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was thinking about making a post &lt;A href="http://https//geonet.esri.com/docs/DOC-7343"&gt;about the scripts in question &lt;/A&gt;it, and I don't want to hijack this one. I will tag you when I do. It has been a low priority because I got my temporary fixes to work on the projects I needed it on, but I would appreciate the input. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;David&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Apr 2016 19:06:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352606#M27643</guid>
      <dc:creator>DavidWasserman</dc:creator>
      <dc:date>2016-04-28T19:06:16Z</dc:date>
    </item>
    <item>
      <title>Re: Issues with ArcPy SpatialReference Class</title>
      <link>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352607#M27644</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Melita,&lt;/P&gt;&lt;P&gt;so you are saying that if the zone number has a single digit, 2 spaces should be added to form the "Name" string.&lt;/P&gt;&lt;P&gt;Is that true throughout the system?&lt;/P&gt;&lt;P&gt;Other, non UTM style names, just the .replace("_", " ") should work?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Apr 2016 08:00:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/issues-with-arcpy-spatialreference-class/m-p/352607#M27644</guid>
      <dc:creator>NeilAyres</dc:creator>
      <dc:date>2016-04-29T08:00:10Z</dc:date>
    </item>
  </channel>
</rss>

