Define Project本地服务包如何在arcgis runtime .net 100.6调用?

你好,我用arcmap 10.2的toolbox->data management tools->projections and transformations->Define Projection对一幅未设置投影坐标系的影像DOM设置投影坐标系,执行成功后将它以geoprocessing package的方式生成gpk(勾选"support Arcgis runtime").然后在arcgis runtime .net 100.6启动此服务,调用代码片段如下:

GeoprocessingParameters gpParams = new GeoprocessingParameters(GeoprocessingExecutionType.AsynchronousSubmit);
gpParams.Inputs["coor_system"] = new GeoprocessingString(projectString);
gpParams.Inputs["in_dataset"] = new GeoprocessingFeatures(new Uri(tifPath));
// Create the job
m_gpJob = m_gpTask.CreateJob(gpParams);

执行后出错,麻烦帮我看看哪里出错了.谢谢.出错信息为:Illegal state: Server job has failed. Invalid return value: c:\users\peter\appdata\local\temp\arcgisruntime_28976\defineprojection_dom\jobs\defineprojection_dom_gpserver\j98a707d142604f029a969ffa2d886c9e\scratch\dom.tif.
已邀请:

朱新颖

赞同来自:

执行gpk的过程中会生成本地的gp服务,在浏览器中输入该url,然后使用参数看可否执行成功?

爱尔兰咖啡~维庚

赞同来自:

{"error":{"code":400,"details":[],"message":"Bad request: POST GPServer/Define Projection/submitJob Dont know how to write special parameter 'in_dataset' of type 'JSON Object' with value 'file:///E:/Data/DEM/54%E5%9D%90%E6%A0%87%E7%B3%BB/DOM_Small/dom.tif'"}}

我通过URL执行结果出错(见附件截图),错误信息如上。我代码是用GeoprocessingFeatures作为参数,而网页显示此参数类型为Gprasterdatalayer。而代码并没有此类型,我应该如何传参才能执行正确,请指导下,谢谢。

要回复问题请先登录注册