AnsweredAssumed Answered

Accessing published GPServer in AddToolbox

Question asked by sclark98 on Jul 29, 2014
Latest reply on Jul 29, 2014 by sclark98

I have a GPServer published as http://<server>/arcgis/rest/services/Geoprocessing/SpatialETLTool_July2014_GISPRD/GPServer/Spatial%20ETL%20Tool

 

In trying to execute the GP in arcobjects, I keep getting a COM error (with no GetMessages). I am trying to track down where the problem lies but I am not clear on what is the toolbox and the tool name. Here's a sample of what I got using the above GPServer:

 

try
IGeoProcessor2 gp = new GeoProcessorClass();
gp.OverwriteOutput = true;
object sev = null;
gp.AddToolbox(@"http://<server>/arcgis/services;Geoprocessing/SpatialETLTool_July2014_GISPRD");
...
IGeoProcessorResult2 results = (IGeoProcessorResult2)gp.Execute("Spatial ETL Tool", parameters, null);

catch
string errorMsgs = gp.GetMessages(ref sev);

 

Is the toolbox and/or tool name wrong?

Outcomes