Extract Data Sample JavaScript API

4407
8
05-04-2016 07:00 AM
Highlighted
New Contributor II

I have a GP service on my ArcServer machine that performs an Extract Data process (clip, zip, and ship).  I would like to call it using the JavaScript API.  When I search for samples using this from the API documentation, it comes back as "0 samples found".   I tend to learn best from studying samples, so this lack of an example is a problem.  There is a sample for the Flex API, but I am trying to move away from Flex.  Any working example code would be appreciated.

Tags (1)
8 Replies
Highlighted
MVP Regular Contributor
Highlighted
New Contributor II

Tim,

This is a nice application, but it does not quite address my issue.  I would like a sample that uses the Extract Data widget (that is, that allows the user to download the shape file for a layer).   Thanks for the link to the sample. It is interesting.

Reply
0 Kudos
Highlighted
Occasional Contributor

This sample can be found if you download the 3.15 or earlier SDK locally. To make it easier, I have attached it to this post as well.

Highlighted
New Contributor

Artemis, thank you for providing an example to extract data.

However, that example does not use the ExtractData widget. Instead, it uses a Geoprocessor and then builds around it.

Is it possible to use this widget with a GP Service, locally hosted on Arcgis Server? If so, how should the service be set up in order to be compatible with the widget?

Reply
0 Kudos
Highlighted
by
Regular Contributor
Reply
0 Kudos
Highlighted
New Contributor III

What is the user and password yracub ?

Have you already tried with an image service too?

Reply
0 Kudos
Highlighted
by
Regular Contributor

You need to put your ArcGIS Online credentials to login, because this ExtractData consumes credits.

You can switch the featureLayer reference to image service' url and Class in the JavaScript panel, and it should work.

JS Bin - Collaborative JavaScript Debugging 

Highlighted
New Contributor III

The consumption of credits is debited from your account or from mine? I couldn't see any change on my organization account credit.

Reply
0 Kudos