<?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: Geoprocessing Tasks - Getting input parameter choices in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29895#M771</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Andrew,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for pointing me in the right direction. Turns out my test project still had a reference to the old SDK, and the problem actually existed between the keyboard and the chair &lt;span class="lia-unicode-emoji" title=":grinning_face_with_smiling_eyes:"&gt;😄&lt;/span&gt;&amp;nbsp; I updated my SDK reference it and was able to find the methods in question.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Mark&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 09 Nov 2012 14:17:33 GMT</pubDate>
    <dc:creator>MarkCollins</dc:creator>
    <dc:date>2012-11-09T14:17:33Z</dc:date>
    <item>
      <title>Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29891#M767</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am trying to figure out how to programmatically get the list of available input parameters for a geoprocessing task and the choice list for the parameters. My end goal is to populate a combo box with the available choices. Here is an example of one of the input params in my service:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Parameter: Day_or_Night_incident &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Data Type: GPString &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Display Name Day or Night incident &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Direction: esriGPParameterDirectionInput &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Default Value: Day &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Parameter Type: esriGPParameterTypeRequired &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Category: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Choice List: [ Day, Night ]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have tried to get them with calls to GetInputAsync like so:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;geoprocessorTask.GetInputAsync("1", "Day_or_Night_incident");&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This does not work, i just get an error message returned of: Error = {"Invalid or missing input parameters."}&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;What is the proper way to get a list of input params and their choices for a GP service?&lt;/STRONG&gt;&lt;SPAN&gt; I couldn't find any SDK samples that do this. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My GP task works fine in ArcMap and when called from the SDK w/ my parameters statically defined so I know there is not an issue with my service.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Mark&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Nov 2012 15:53:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29891#M767</guid>
      <dc:creator>MarkCollins</dc:creator>
      <dc:date>2012-11-08T15:53:59Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29892#M768</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;At the 3.0 API there is a GetServiceInfoAsync() method.&amp;nbsp; It'll return GPServiceInfo.&amp;nbsp; GPServiceInfo has a parameters[] method... Give that a try.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A class="jive-link-external-small" href="http://resources.arcgis.com/en/help/silverlight-api/apiref/api_start.htm?ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfoAsync.html" rel="nofollow" target="_blank"&gt;http://resources.arcgis.com/en/help/silverlight-api/apiref/api_start.htm?ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfoAsync.html&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Nov 2012 13:20:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29892#M768</guid>
      <dc:creator>deleted-user-ATjHIWsdQYmT</dc:creator>
      <dc:date>2012-11-09T13:20:39Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29893#M769</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Andrew, &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This appears to be exactly what I was looking for, thank you! Do you have happen to know if there is something similar in WPF SDK as well? I'm not finding a GetServiceInfo call on that API.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Mark&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Nov 2012 13:47:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29893#M769</guid>
      <dc:creator>MarkCollins</dc:creator>
      <dc:date>2012-11-09T13:47:06Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29894#M770</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Andrew, &lt;BR /&gt;&lt;BR /&gt;This appears to be exactly what I was looking for, thank you! Do you have happen to know if there is something similar in WPF SDK as well? I'm not finding a GetServiceInfo call on that API.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Mark&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't use WPF, but it appears there are two methods, one async and one synchronous.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/runtime-wpf/apiref/ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfo.html"&gt;http://resources.arcgis.com/en/help/runtime-wpf/apiref/ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfo.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/runtime-wpf/apiref/ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfoAsync.html"&gt;http://resources.arcgis.com/en/help/runtime-wpf/apiref/ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfoAsync.html&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Nov 2012 14:07:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29894#M770</guid>
      <dc:creator>deleted-user-ATjHIWsdQYmT</dc:creator>
      <dc:date>2012-11-09T14:07:18Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29895#M771</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Andrew,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for pointing me in the right direction. Turns out my test project still had a reference to the old SDK, and the problem actually existed between the keyboard and the chair &lt;span class="lia-unicode-emoji" title=":grinning_face_with_smiling_eyes:"&gt;😄&lt;/span&gt;&amp;nbsp; I updated my SDK reference it and was able to find the methods in question.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Mark&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Nov 2012 14:17:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29895#M771</guid>
      <dc:creator>MarkCollins</dc:creator>
      <dc:date>2012-11-09T14:17:33Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29896#M772</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I think I'm using the same toolbox (Emergency Response Geoprocessing Tools) as Mark.&amp;nbsp; I've tried using some of the Geoprocessing tasks from the API samples but have yet to succsesfully populate a comb box with a list of parameter values.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For one of the examples the following is used to call the parameters:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt; List&amp;lt;GPParameter&amp;gt; parameters = new List&amp;lt;GPParameter&amp;gt;();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; parameters.Add(new GPFeatureRecordSetLayer("Input_Features", mapPoint));
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; parameters.Add(new GPString("Height", HeightTextBox.Text));
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; parameters.Add(new GPLinearUnit("Distance", esriUnits.esriMiles, Convert.ToDouble(MilesTextBox.Text)));
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Aside from making sure the xaml code names match those in the C# code, what else needs to happen to get a list of parameters in a combo box?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Dec 2021 21:12:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29896#M772</guid>
      <dc:creator>danielchaboya</dc:creator>
      <dc:date>2021-12-10T21:12:01Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29897#M773</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Check this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/runtime-wpf/apiref/index.html?ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfo.html"&gt;http://resources.arcgis.com/en/help/runtime-wpf/apiref/index.html?ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Tasks.Geoprocessor~GetServiceInfo.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It will return GPServiceInfo() which you can parse and get the input parameters.&amp;nbsp; Then take those parameters and put them into a list, and use that to populate your combo box.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 12:31:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29897#M773</guid>
      <dc:creator>deleted-user-ATjHIWsdQYmT</dc:creator>
      <dc:date>2012-11-15T12:31:43Z</dc:date>
    </item>
    <item>
      <title>Re: Geoprocessing Tasks - Getting input parameter choices</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29898#M774</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for the response Andrew.&amp;nbsp; Your solution kind of makes sense to me, but I'm not a programmer so it'd be difficult for me to develop that bit of code (either way i'll give it a shot).&amp;nbsp; Up untill now i've hacked my way, with the help of the samples, in to developing a decent web app.&amp;nbsp; The Emergency Response tool has proven to be a formidable defensemen ( maybe more like a Ray Lewis) and has stopped me from moving any further on this project :cool:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 14:27:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/geoprocessing-tasks-getting-input-parameter/m-p/29898#M774</guid>
      <dc:creator>danielchaboya</dc:creator>
      <dc:date>2012-11-15T14:27:36Z</dc:date>
    </item>
  </channel>
</rss>

