<?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: Sending string to custom GP Service in a silverlight app in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44428#M1208</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;As far as documentation goes, I learned what I needed from the 'Geoprocessing' node of the samples at &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/samples/start.htm"&gt;http://help.arcgis.com/en/webapi/silverlight/samples/start.htm&lt;/A&gt;&lt;SPAN&gt;, and the API Reference at &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/apiref/api_start.htm"&gt;http://help.arcgis.com/en/webapi/silverlight/apiref/api_start.htm&lt;/A&gt;&lt;SPAN&gt; for the Geoprocessor class under ESRI.ArcGIS.Client.Tasks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 08 Mar 2012 18:54:06 GMT</pubDate>
    <dc:creator>markcheyne</dc:creator>
    <dc:date>2012-03-08T18:54:06Z</dc:date>
    <item>
      <title>Sending string to custom GP Service in a silverlight app</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44425#M1205</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have a custom gp service that is writing to a text file.&amp;nbsp; If I paste this &lt;/SPAN&gt;&lt;A href="http://mywebsite.com/ArcGIS/rest/services/Geoprocessing/gpServiceTest/GPServer/gpService/submitJob?Input=WOWee"&gt;http://mywebsite.com/ArcGIS/rest/services/Geoprocessing/gpServiceTest/GPServer/gpService/submitJob?Input=WOWee&lt;/A&gt;&lt;SPAN&gt;! into the browser, my gp service works.&amp;nbsp; I can't figure out the syntax needed to send this through c#.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is what I have:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;SUBMITGEOMETRY is a constant string in the Densify class&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;Densify.SUMBITGEOMETRY = "&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://gis.mustangeng.com/ArcGIS/rest/services/Geoprocessing/gpServiceTest/GPServer/gpService/submitJob" rel="nofollow" target="_blank"&gt;http://gis.mustangeng.com/ArcGIS/rest/services/Geoprocessing/gpServiceTest/GPServer/gpService/submitJob&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Uri serviceUri = new Uri(Densify.SUBMITGEOMETRY);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;string s = "?Input=" + String.Join(",", dictElevat.Keys.Select(o =&amp;gt; o.ToString()).ToArray());&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;webClient1.UploadStringAsync(serviceUri, "POST", s);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the rest page of my gp service&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; "name" : "gpService", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; "displayName" : "gpService", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; "category" : "", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp; "helpUrl" : "&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://myhostmachine/arcgisoutput/Geoprocessing_gpServiceTest/TestFuncs.htm" rel="nofollow" target="_blank"&gt;http://myhostmachine/arcgisoutput/Geoprocessing_gpServiceTest/TestFuncs.htm&lt;/A&gt;&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; "executionType" : "esriExecutionTypeAsynchronous", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; "parameters" : [&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "name" : "Input", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "dataType" : "GPString", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "displayName" : "Input", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "direction" : "esriGPParameterDirectionInput", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "defaultValue" : "This is a test in ArcMap!", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "parameterType" : "esriGPParameterTypeRequired", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "category" : "", &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "choiceList" : []&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; ]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2012 12:12:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44425#M1205</guid>
      <dc:creator>justinperez</dc:creator>
      <dc:date>2012-03-02T12:12:38Z</dc:date>
    </item>
    <item>
      <title>Re: Sending string to custom GP Service in a silverlight app</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44426#M1206</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Once you have clientaccesspolicy in place, the code looks like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You can subscribe to StatusUpdated and\or JobCompleted to see JobInfo. GPString need to include the parameter name "Input" and the value, in this case the string you want to write to file.&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
&amp;nbsp;&amp;nbsp; var geoprocessorTask = new Geoprocessor("http://gis.mustangeng.com/ArcGIS/rest/services/Geoprocessing/gpServiceTest/GPServer/gpService");
&amp;nbsp;&amp;nbsp; geoprocessorTask.StatusUpdated += (s, e) =&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MessageBox.Show(string.Format("StatusUpdated \nID: {0}\nStatus: {1}", e.JobInfo.JobId, e.JobInfo.JobStatus));
&amp;nbsp;&amp;nbsp;&amp;nbsp; };
&amp;nbsp;&amp;nbsp; geoprocessorTask.JobCompleted += (s, e) =&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MessageBox.Show(string.Format("JobCompleted \nID: {0}\nStatus: {1}", e.JobInfo.JobId, e.JobInfo.JobStatus));
&amp;nbsp;&amp;nbsp;&amp;nbsp; };
&amp;nbsp;&amp;nbsp; var gpParameters = new List&amp;lt;GPParameter&amp;gt;();
&amp;nbsp;&amp;nbsp; gpParameters.Add(new GPString("Input", "http://mywebsite.com/ArcGIS/rest/services/Geoprocessing/gpServiceTest/GPServer/gpService/submitJob?Input=WOWee"));
&amp;nbsp;&amp;nbsp; geoprocessorTask.SubmitJobAsync(gpParameters);
&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Dec 2021 21:42:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44426#M1206</guid>
      <dc:creator>JenniferNery</dc:creator>
      <dc:date>2021-12-10T21:42:15Z</dc:date>
    </item>
    <item>
      <title>Re: Sending string to custom GP Service in a silverlight app</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44427#M1207</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks a bunch!&amp;nbsp; Do you know where this is documented?&amp;nbsp; The GPParameter piece specifically.&amp;nbsp; I'm using some of the code samples from the silverlight api with this but &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So the Geoprocessor is a delegate?&amp;nbsp; Is this documented somewhere?&amp;nbsp; Thanks again!&amp;nbsp; (Premature thanks..hope I don't have to return)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2012 16:40:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44427#M1207</guid>
      <dc:creator>justinperez</dc:creator>
      <dc:date>2012-03-02T16:40:14Z</dc:date>
    </item>
    <item>
      <title>Re: Sending string to custom GP Service in a silverlight app</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44428#M1208</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;As far as documentation goes, I learned what I needed from the 'Geoprocessing' node of the samples at &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/samples/start.htm"&gt;http://help.arcgis.com/en/webapi/silverlight/samples/start.htm&lt;/A&gt;&lt;SPAN&gt;, and the API Reference at &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/webapi/silverlight/apiref/api_start.htm"&gt;http://help.arcgis.com/en/webapi/silverlight/apiref/api_start.htm&lt;/A&gt;&lt;SPAN&gt; for the Geoprocessor class under ESRI.ArcGIS.Client.Tasks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2012 18:54:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/sending-string-to-custom-gp-service-in-a/m-p/44428#M1208</guid>
      <dc:creator>markcheyne</dc:creator>
      <dc:date>2012-03-08T18:54:06Z</dc:date>
    </item>
  </channel>
</rss>

