<?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: Output parameter in script tool doesn't work, why? in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/output-parameter-in-script-tool-doesn-t-work-why/m-p/144737#M11239</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Great help, Thank you&amp;nbsp;&lt;/P&gt;&lt;P&gt;I changed the parameter value to string and it worked.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 28 Feb 2017 02:50:38 GMT</pubDate>
    <dc:creator>babakkasraei</dc:creator>
    <dc:date>2017-02-28T02:50:38Z</dc:date>
    <item>
      <title>Output parameter in script tool doesn't work, why?</title>
      <link>https://community.esri.com/t5/python-questions/output-parameter-in-script-tool-doesn-t-work-why/m-p/144735#M11237</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp;&lt;/P&gt;&lt;P&gt;I try to specify an argument for output shape file to create it (outputShape = sys.argv[&lt;SPAN style="color: #0000ff;"&gt;4&lt;/SPAN&gt;])&lt;/P&gt;&lt;P&gt;and to get the shape file name from parameters. Then I set the output file parameter as a feature class and output. But my output parameter doesn't work. the script is as follows.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Why Cannot I get the output name from parameters?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;-------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;SPAN style="color: #808080;"&gt;# the path to workplace
&lt;/SPAN&gt;arcpy.env.workspace = sys.argv[&lt;SPAN style="color: #0000ff;"&gt;1&lt;/SPAN&gt;]
&lt;SPAN style="color: #808080;"&gt;# The path to the CSV file
&lt;/SPAN&gt;inputCSVfile = sys.argv[&lt;SPAN style="color: #0000ff;"&gt;2&lt;/SPAN&gt;]
&lt;SPAN style="color: #808080;"&gt;#Get the template shapefile
&lt;/SPAN&gt;templateShapeFile = sys.argv[&lt;SPAN style="color: #0000ff;"&gt;3&lt;/SPAN&gt;]
&lt;SPAN style="color: #808080;"&gt;# The name of the output shape file
&lt;/SPAN&gt;outputShape = sys.argv[&lt;SPAN style="color: #0000ff;"&gt;4&lt;/SPAN&gt;]&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;&amp;lt;&amp;lt;-------------------------------------------------- Here???? it doesn't work,Why???&amp;nbsp;&amp;nbsp; 

&lt;SPAN style="color: #808080;"&gt;# open CSV file
&lt;/SPAN&gt;inFile = &lt;SPAN style="color: #000080;"&gt;open&lt;/SPAN&gt;(inputCSVfile, &lt;SPAN style="color: #008000; font-weight: bold;"&gt;"r"&lt;/SPAN&gt;)

&lt;SPAN style="color: #808080;"&gt;# create feature class
&lt;/SPAN&gt;arcpy.CreateFeatureclass_management(arcpy.env.workspace, outputShape, &lt;SPAN style="color: #008000; font-weight: bold;"&gt;"POINT"&lt;/SPAN&gt;, templateShapeFile, &lt;SPAN style="color: #008000; font-weight: bold;"&gt;"DISABLED"&lt;/SPAN&gt;, &lt;SPAN style="color: #008000; font-weight: bold;"&gt;"DISABLED"&lt;/SPAN&gt;, templateShapeFile)&lt;/PRE&gt;&lt;P&gt;---------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/330663_pastedImage_3.png" style="width: auto; height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-2 jive-image" src="https://community.esri.com/legacyfs/online/330664_pastedImage_4.png" style="width: 804px; height: 281px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 07:55:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/output-parameter-in-script-tool-doesn-t-work-why/m-p/144735#M11237</guid>
      <dc:creator>babakkasraei</dc:creator>
      <dc:date>2021-12-11T07:55:22Z</dc:date>
    </item>
    <item>
      <title>Re: Output parameter in script tool doesn't work, why?</title>
      <link>https://community.esri.com/t5/python-questions/output-parameter-in-script-tool-doesn-t-work-why/m-p/144736#M11238</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The second parameter of the&amp;nbsp;arcpy.CreateFeatureclass_management function should be a string and not a Feature Class&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Feb 2017 06:11:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/output-parameter-in-script-tool-doesn-t-work-why/m-p/144736#M11238</guid>
      <dc:creator>FC_Basson</dc:creator>
      <dc:date>2017-02-27T06:11:08Z</dc:date>
    </item>
    <item>
      <title>Re: Output parameter in script tool doesn't work, why?</title>
      <link>https://community.esri.com/t5/python-questions/output-parameter-in-script-tool-doesn-t-work-why/m-p/144737#M11239</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Great help, Thank you&amp;nbsp;&lt;/P&gt;&lt;P&gt;I changed the parameter value to string and it worked.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Feb 2017 02:50:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/output-parameter-in-script-tool-doesn-t-work-why/m-p/144737#M11239</guid>
      <dc:creator>babakkasraei</dc:creator>
      <dc:date>2017-02-28T02:50:38Z</dc:date>
    </item>
  </channel>
</rss>

