AnsweredAssumed Answered

Upload file to server with ArcObjects

Question asked by csouzaimg-com-br-esridist Employee on Jul 13, 2016

Hi

 

I create a geoprocess in arcgis server with upload capacity. This service works fine when tested in browser, runtime and javascript api, but not with ArcObjects.

I could did the upload by IServiceUploadsClient interface. The itemID was returned in IUploadItem interface, but I do not know how use this id in IGPDataFile interface.

I tried:

IGPDataFile gpDataFile = new GPDataFileClass();

gpDataFile.File = "{'itemID':'" + uploadItem.ID + "'}";

 

I tried too:

gpDataFile.DataType = "zip";

gpDataFile.Data = new ESRI.ArcGIS.GeoDatabaseDistributed.GDSData();

gpDataFile.Data.TransportType = ESRI.ArcGIS.GeoDatabaseDistributed.esriGDSTransportType.esriGDSTransportTypeUpload;

 

In other time, I tried gpDataFile.File = uploadItem.ID;

 

I do not know how do this.

 

Someone can helpe me?

 

Thanks

 

Cristian

Outcomes