<?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 Call an arcpy script from C# code? in Geoprocessing Questions</title>
    <link>https://community.esri.com/t5/geoprocessing-questions/call-an-arcpy-script-from-c-code/m-p/688818#M22846</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Does anyone know if it is possible to call a python script that uses the arcpy library directly from C#?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't want to publish a gp service because it is a royal pain in the you know what.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I just have a py script that does some geoprocessing and i want to call that from my C# code.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I can call other py scripts from C# using a shell command. But what about complex input types like Feature Set? How would i represent those as parameters to the py call?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 29 May 2013 14:37:17 GMT</pubDate>
    <dc:creator>KeG</dc:creator>
    <dc:date>2013-05-29T14:37:17Z</dc:date>
    <item>
      <title>Call an arcpy script from C# code?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/call-an-arcpy-script-from-c-code/m-p/688818#M22846</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Does anyone know if it is possible to call a python script that uses the arcpy library directly from C#?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't want to publish a gp service because it is a royal pain in the you know what.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I just have a py script that does some geoprocessing and i want to call that from my C# code.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I can call other py scripts from C# using a shell command. But what about complex input types like Feature Set? How would i represent those as parameters to the py call?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 May 2013 14:37:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/call-an-arcpy-script-from-c-code/m-p/688818#M22846</guid>
      <dc:creator>KeG</dc:creator>
      <dc:date>2013-05-29T14:37:17Z</dc:date>
    </item>
    <item>
      <title>Re: Call an arcpy script from C# code?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/call-an-arcpy-script-from-c-code/m-p/688819#M22847</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Ke&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;All data sources of ArcPy can be represented as strings as well as more complex types (sometimes).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The easiest way is to run the tool once from ArcMap and see what the strings are.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Do not load data into ArcMap so you will get the real string representation of all the data types.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Have Fun&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Mody&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 May 2013 04:23:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/call-an-arcpy-script-from-c-code/m-p/688819#M22847</guid>
      <dc:creator>ModyBuchbinder</dc:creator>
      <dc:date>2013-05-30T04:23:06Z</dc:date>
    </item>
    <item>
      <title>Re: Call an arcpy script from C# code?</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/call-an-arcpy-script-from-c-code/m-p/688820#M22848</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;what does the 'sometimes' apply to?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;My main input param is typically Feature Set.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;In the old tbx style i needed to have a dummy schema setup on this so that in C# code i could get a reference to the recordset and then load it with features from a json representation.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't see how this can be done without the schema in there.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Also, something makes me think that esri may have some tool that they use to load features into the feature set from a json representation, as that is how they go over the wire to the ags rest endpoint. but is that method exposed or in the black box of ags?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 May 2013 19:18:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/call-an-arcpy-script-from-c-code/m-p/688820#M22848</guid>
      <dc:creator>KeG</dc:creator>
      <dc:date>2013-05-30T19:18:58Z</dc:date>
    </item>
  </channel>
</rss>

