<?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: Python has no attributes in Geoprocessing Questions</title>
    <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57531#M1987</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hallo Dan Patterson,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;yes, This was the solution. Instead of using sys.arcv I haves choosen "GetParameterAsText" and now it works very well. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you very much for your help&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Holm&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 30 Jun 2010 21:13:25 GMT</pubDate>
    <dc:creator>HolmSeifert</dc:creator>
    <dc:date>2010-06-30T21:13:25Z</dc:date>
    <item>
      <title>Python has no attributes</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57529#M1985</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi everyone,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;i have a question.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;have anyone an idea how i can solve this problem, occuring when runnig a pythin script.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;type 'exceptions.AttributeError'&amp;gt;: 'module' object has no attribute 'arcv'&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Failed to execute (Script).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Jun 2010 00:11:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57529#M1985</guid>
      <dc:creator>HolmSeifert</dc:creator>
      <dc:date>2010-06-29T00:11:02Z</dc:date>
    </item>
    <item>
      <title>Re: Python has no attributes</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57530#M1986</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;showing the script would help&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;perhaps it is supposed to be argv as in sys.argv&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Jun 2010 09:15:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57530#M1986</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2010-06-29T09:15:29Z</dc:date>
    </item>
    <item>
      <title>Re: Python has no attributes</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57531#M1987</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hallo Dan Patterson,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;yes, This was the solution. Instead of using sys.arcv I haves choosen "GetParameterAsText" and now it works very well. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you very much for your help&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Holm&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Jun 2010 21:13:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57531#M1987</guid>
      <dc:creator>HolmSeifert</dc:creator>
      <dc:date>2010-06-30T21:13:25Z</dc:date>
    </item>
    <item>
      <title>Re: Python has no attributes</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57532#M1988</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;it is argv not arcv&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;in any event, sys.argv and GetParameterAsText are equivalent if you need string representations of the input, sys.argv allows for the passing of numbers&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Jul 2010 08:01:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57532#M1988</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2010-07-01T08:01:49Z</dc:date>
    </item>
    <item>
      <title>Re: Python has no attributes</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57533#M1989</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;From my experience, GetParameterAsText() and GetParameter() are preferable to sys.argv[].&amp;nbsp; sys.argv[] has a character limit (I think it's 1024) while GetParameterAsText() doesn't have a limit.&amp;nbsp; I know that 1024 is a lot, but I have exceeded it on occasion for data buried in a deep folder hierarchy.&amp;nbsp; If you need the raw number (integer, double), use GetParameter().&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;(Prior to 9.0, I think, GetParameterAsText() wouldn't work when called from the OS prompt, so you had to use sys.argv[] unless you always ran as a script tool. This limitation was fixed at 9.0)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 04 Jul 2010 20:16:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57533#M1989</guid>
      <dc:creator>DaleHoneycutt</dc:creator>
      <dc:date>2010-07-04T20:16:13Z</dc:date>
    </item>
    <item>
      <title>Re: Python has no attributes</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57534#M1990</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think I have a similar problem. I am trying to run a script as a script tool in ArcCatalog, however when I do I get this error message:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;type 'exceptions.AttributeError'&amp;gt;: 'module' object has no attribute 'GetParamaterAsText'&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Failed to execute (SlopeRoad).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Though I have directed the inputs to be GetParamaterAsText in the script, I have copied some of the script to show what I have done. Is there something I have not added when changing it to as script tool with 'GetParamaterAsText' as the script works when I hard code the inputs??&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;import arcpy, os, string, sys&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;#overwrite existing data if there&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;arcpy.env.overwriteOutput = True&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;#check out the ArcGIS Spatial Analyst extension license&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;arcpy.CheckOutExtension("Spatial")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;#&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Service_Areas = arcpy.GetParamaterAsText(0)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;DEM = arcpy.GetParamaterAsText(1)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Mask_NOW = arcpy.GetParamaterAsText(2)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;OutDirectory = arcpy.GetParameterAsText(3)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;#&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;arcpy.env.extent = Service_Areas&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;#cell size&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;arcpy.env.cellSize = DEM&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;#mask&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;arcpy.env.mask = Mask_NOW&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;GAslope = arcpy.sa.Slope(DEM, "PERCENT_RISE")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;GAslope.save(OutDirectory + "\sloperaster.gdb\GAslope")&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for any help! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Apr 2011 01:05:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57534#M1990</guid>
      <dc:creator>SharynHickey1</dc:creator>
      <dc:date>2011-04-05T01:05:56Z</dc:date>
    </item>
    <item>
      <title>Re: Python has no attributes</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57535#M1991</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Sharynh&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://forums.arcgis.com/threads/27483-module-object-has-no-attribute-GetParamaterAsText"&gt;http://forums.arcgis.com/threads/27483-module-object-has-no-attribute-GetParamaterAsText&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;spelling issues is the source of your problem&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Apr 2011 09:57:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/python-has-no-attributes/m-p/57535#M1991</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2011-04-05T09:57:39Z</dc:date>
    </item>
  </channel>
</rss>

