<?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: script does not work in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446055#M35014</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;JSkinn3 I would like you to have a look at a script for me pleeeeaaaaasssssseeeeeeeee...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 30 Dec 2011 21:42:44 GMT</pubDate>
    <dc:creator>GerniceMuhamed</dc:creator>
    <dc:date>2011-12-30T21:42:44Z</dc:date>
    <item>
      <title>script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446034#M34993</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi can some please assist me in reprojecting shapefiles. I want to reproject it in Geographic Coordinate System WGS 1984 and then into the Projected Coordinate System ???World_Cylindrical_Equal_Area..My script does not work..keeps telling me that there is an invalid syntax..When it reaches the &lt;/SPAN&gt;&lt;STRONG&gt;resFC&lt;/STRONG&gt;&lt;SPAN&gt; i get that invalid syntax at the line&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This is what i have&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;if sr.Name == "Unknown":&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;# skip&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; continue&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;else:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;# Determine the new output feature class path and name&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; outFeatureClass = os.path.join(outWorkspace, infc.strip(".shp")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;# Set output coordinate system&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;resFc = outFeatureClass + "," + ("&amp;lt;install directory&amp;gt;/Coordinate Systems/Projected Coordinate Systems/WGS 1984.prj/Cylindrical Equal Area (world).prj")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&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; arcpy.Project_management(infc, outFeatureClass, outCS)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&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; arcpy.AddMessage("The shapefiiles have been reprojected")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&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; print "Get Area Info...."&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 12:06:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446034#M34993</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T12:06:15Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446035#M34994</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Can you post the entire script?&amp;nbsp; Be sure to enclose it with &lt;/SPAN&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;&lt;/PRE&gt;&lt;SPAN&gt; tags (the # symbol) to preserve indentation.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 13:46:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446035#M34994</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2011-12-30T13:46:34Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446036#M34995</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;# Import system modules
import arcpy
from arcpy import env
import os, glob
# Set environment settings
arcpy.env.workspace = ("G:/Animals")

# Set local variables
outWorkspace = ("G:/Animals/Reproject_Out.gdb")

# Use ListFeatureClasses to generate a list of shapefiles in the
#&amp;nbsp; workspace shown above.
fcList = arcpy.ListFeatureClasses()
print fcList

# Set coordinate system only for those inputs which have a defined spatial reference
for infc in fcList:
# Determine if the input has a defined coordinate system
 desc = arcpy.Describe(Animals)
 sr = desc.spatialReference

if sr.Name == "Unknown":
# skip
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; continue
else:
# Determine the new output feature class path and name
&amp;nbsp;&amp;nbsp;&amp;nbsp; outFeatureClass = os.path.join(outWorkspace, infc.strip(".shp")
# Set output coordinate system
&amp;nbsp;&amp;nbsp;&amp;nbsp; resFc = outFeatureClass + "," + ("&amp;lt;install directory&amp;gt;/Coordinate Systems/Projected Coordinate Systems/WGS 1984.prj/Cylindrical Equal Area (world).prj")
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.Project_management(infc, outFeatureClass, outCS)
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.AddMessage("The shapefiiles have been reprojected")
&amp;nbsp;&amp;nbsp;&amp;nbsp; print "Get Area Info...."
&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; 
# Print message to say the two fields are being added
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.AddMessage("Adding fields F_AREA and C_AREA, calculating field values...")

# Execute AddField twice for two new fields&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.AddField_management(Animals, F_AREA, "LONG", "", fieldLength)
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.AddField_management(Animals, C_AREA, "LONG", "", fieldLength)
try:
# Set the current workspace (to avoid having to specify the full path to the feature classes each time)
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.env.workspace = outCS

# Process: Calculate Areas...
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.CalculateAreas_stats(outCS, outCS_output_area)
except:
# If an error occurred when running the tool, print out the error message.
&amp;nbsp;&amp;nbsp;&amp;nbsp; print arcpy.GetMessages()
import math&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 19:56:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446036#M34995</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2021-12-11T19:56:18Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446037#M34996</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This is what I have so far...I have other script to write but need to get this working first.. So JSkinn3 can you please let me know what you see is wrong...I have tried to use the wrap around the code hope its is better...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 14:41:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446037#M34996</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T14:41:38Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446038#M34997</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;When you are projecting the shapefile, I don't see where you assigned a coordinate system to the 'outCS' variable.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;arcpy.Project_management(infc, outFeatureClass, outCS)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 14:54:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446038#M34997</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2011-12-30T14:54:28Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446039#M34998</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The shapefiles i have dont have any projection its unknown... i am setting it to 2 different projections wgs84 first then Cylindrical Equal Area. i am not sure how to do it but thought this below would reproject it...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; Set output coordinate system&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; resFc = outFeatureClass + "," + ("&amp;lt;install directory&amp;gt;/Coordinate Systems/Projected Coordinate Systems/WGS 1984.prj/Cylindrical Equal Area (world).prj")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.Project_management(infc, outFeatureClass, outCS)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 15:00:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446039#M34998</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T15:00:03Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446040#M34999</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You'll probably need to define the projection first using arcpy.DefineProjection_management&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//001700000077000000"&gt;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//001700000077000000&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Then re-project the data as you have now using the arcpy.Project_management tool.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 15:50:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446040#M34999</guid>
      <dc:creator>EokNgo</dc:creator>
      <dc:date>2011-12-30T15:50:38Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446041#M35000</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;So I dont have to use a script to project the data into WGS84?????? Do I remove the resFc....... part of the script and just have arcpy.Project_management tool?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:02:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446041#M35000</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T16:02:09Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446042#M35001</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You will need to first define the projection of the shapefile that has an Unknown coordinate system, and then reproject the shapefile to your desired coordinate system.&amp;nbsp; I highlighted in bold the areas I changed:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;# Import system modules
import arcpy
from arcpy import env
import os, glob
# Set environment settings
arcpy.env.workspace = ("G:/Animals")

# Set local variables
outWorkspace = ("G:/Animals/Reproject_Out.gdb")

# Use ListFeatureClasses to generate a list of shapefiles in the
#&amp;nbsp; workspace shown above.
fcList = arcpy.ListFeatureClasses()
print fcList

# Set coordinate system only for those inputs which have a defined spatial reference
for infc in fcList:
# Determine if the input has a defined coordinate system
 desc = arcpy.Describe(&lt;STRONG&gt;"Animals.shp"&lt;/STRONG&gt;)
 sr = desc.spatialReference

if sr.name == "Unknown":
# Determine the new output feature class path and name
&amp;nbsp;&amp;nbsp;&amp;nbsp; outFeatureClass = os.path.join(outWorkspace, infc.strip(".shp")&lt;STRONG&gt;)&lt;/STRONG&gt;
# Set output coordinate system
&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; outCS = "Coordinate Systems\Geographic Coordinate Systems\World\WGS 1984.prj"
&amp;nbsp;&amp;nbsp;&amp;nbsp; outCS2 = "Coordinate Systems\Projected Coordinate Systems\World\Cylindrical Equal Area (world).prj"
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.DefineProjection_management(infc, outCS)&lt;/STRONG&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.Project_management(infc, outFeatureClass, outCS2)
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.AddMessage("The shapefiiles have been reprojected")&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 19:56:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446042#M35001</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2021-12-11T19:56:21Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446043#M35002</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;ok thanx I will try it now&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:07:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446043#M35002</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T16:07:03Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446044#M35003</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;One other change you should make.&amp;nbsp; Change the following line:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;desc = arcpy.Describe("Animals.shp")&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;to&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;desc = arcpy.Describe(infc)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:11:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446044#M35003</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2011-12-30T16:11:19Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446045#M35004</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Now its telling me continue is not properly looped&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:15:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446045#M35004</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T16:15:58Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446046#M35005</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You will not have to use 'continue'.&amp;nbsp; You should have your functions under the 'if' statement (since you want to project all shapefiles with an Unknown coordinate system), and 'pass' under your 'else' statement.&amp;nbsp; Pass will skip the shapefiles that have a coordinate system defined:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;if sr.name == "Unknown":&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;# Determine the new output feature class path and name&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; outFeatureClass = os.path.join(outWorkspace, infc.strip(".shp"))&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;# Set output coordinate system&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; outCS = "Coordinate Systems\Geographic Coordinate Systems\World\WGS 1984.prj"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; outCS2 = "Coordinate Systems\Projected Coordinate Systems\World\Cylindrical Equal Area (world).prj"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.DefineProjection_management(infc, outCS)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.Project_management(infc, outFeatureClass, outCS2)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.AddMessage("The shapefiiles have been reprojected")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; print "Get Area Info...."&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;else:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; pass&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:21:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446046#M35005</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2011-12-30T16:21:51Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446047#M35006</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You will not need to use 'continue'.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;if sr.name == "Unknown":
# Determine the new output feature class path and name
&amp;nbsp;&amp;nbsp;&amp;nbsp; outFeatureClass = os.path.join(outWorkspace, infc.strip(".shp"))
# Set output coordinate system
&amp;nbsp;&amp;nbsp;&amp;nbsp; outCS = "Coordinate Systems\Geographic Coordinate Systems\World\WGS 1984.prj"
&amp;nbsp;&amp;nbsp;&amp;nbsp; outCS2 = "Coordinate Systems\Projected Coordinate Systems\World\Cylindrical Equal Area (world).prj"
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.DefineProjection_management(infc, outCS)
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.Project_management(infc, outFeatureClass, outCS2)
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.AddMessage("The shapefiiles have been reprojected")
&amp;nbsp;&amp;nbsp;&amp;nbsp; print "Get Area Info...."&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 19:56:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446047#M35006</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2021-12-11T19:56:23Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446048#M35007</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I got another problem...got this error if sr.Name == "Unknown":&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;NameError: name 'sr' is not defined...sr = desc.spatialReference...Doesn't this define it...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:29:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446048#M35007</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T16:29:07Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446049#M35008</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The arcpy module is case-sensitive.&amp;nbsp; You will need to change it to sr.name.&amp;nbsp; If you copy and paste the code I uploaded into Pythonwin, it should run successfully.&amp;nbsp; I don't believe I changed any of the paths.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:33:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446049#M35008</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2011-12-30T16:33:28Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446050#M35009</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I copied it and still got an invalid syntax error at outCS...I guess i am bad lucky..cause i get an error every time i correct something&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 16:41:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446050#M35009</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T16:41:47Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446051#M35010</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Not sure why the copy/paste did not work.&amp;nbsp; You were receiving your initial error because you were missing a parentheses at the end of the following line:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;outFeatureClass = os.path.join(outWorkspace, infc.strip(".shp")&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Should be:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;outFeatureClass = os.path.join(outWorkspace, infc.strip(".shp"))&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 17:16:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446051#M35010</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2011-12-30T17:16:43Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446052#M35011</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I got it to not give an error..thanx much JSkinn3...Much appreciated&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 17:18:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446052#M35011</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T17:18:48Z</dc:date>
    </item>
    <item>
      <title>Re: script does not work</title>
      <link>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446053#M35012</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This is what my script did...[]...Did you get this?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 30 Dec 2011 17:22:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/script-does-not-work/m-p/446053#M35012</guid>
      <dc:creator>GerniceMuhamed</dc:creator>
      <dc:date>2011-12-30T17:22:54Z</dc:date>
    </item>
  </channel>
</rss>

