Select to view content in your preferred language

Geoprocessing widget doesn't work

2792
4
Jump to solution
03-02-2014 01:27 AM
fatizanady
Deactivated User
hi everyone,

for the geoprocessing widget (GeoprocessingWidget_ExtractData) wel be functional in my project flex
viewer i'm follow the following
steps:
1 - I publish the map service.
2 - I share the service in the same folder where I already publish the map service.
3 - in the Config.xml I add this:
 <widgetgroup label="Tâches de Geotraitement">                 <widget label="Extraction des données"                 icon="assets/images/i_layers.png"                 config="widgets/Geoprocessing/GeoprocessingWidget_ExtractData.xml"                 url="widgets/Geoprocessing/GeoprocessingWidget.swf"/>                         <widget label="buffer" left="600" top="90"            icon="widgets/BufferDistance/assets/images/i_buffer40.png"           config="widgets/BufferDistance/BufferDistanceWidget.xml"           url="widgets/BufferDistance/BufferDistanceWidget.swf"/>         </widgetgroup>

4 - in the GeoprocessingWidget_ExtractData I add this:

 <?xml version="1.0"?> <configuration label="Données Extrait">     <description>Extraire des données et télécharger fichier zip</description>     <taskurl>http://localhost:6080/arcgis/rest/services/geoprocessing/ExtractZionData/GPServer/ExtractZionData</taskurl>     <helpurl>http://localhost:6080/arcgis/rest/directories/arcgisoutput/geoprocessing/ExtractZionData_GPServer/geoprocessing_ExtractZionData/ExtractZionData.htm  </helpurl>          <inputparams>         <param name="Area_of_Interest"                geometrytype="polygon"                label="1. Select area"                required="true"                type="featurerecordset"                visible="true">             <renderer type="simple">                 <defaultsymbol alpha="0.5"                                color="0xFFFFFF"                                type="simplefill">                     <outline width="1" color="0x000000"/>                 </defaultsymbol>             </renderer>         </param>         <param name="Layers_to_Clip"                defaultvalue="Research_areas , Roads , Springs , Zion park boundary "                label="2. Select layers to extract"                required="true"                type="multivalue"                visible="true">             <choicelist>                 <choice value="Research_areas"/>                 <choice value="Tracts"/>                 <choice value="Roads"/>                 <choice value=" Trails"/>                 <choice value="Springs"/>                 <choice value="Streams"/>                 <choice value="Zion park boundary"/>                 <choice value="Hillshade "/>             </choicelist>         </param>                  <param name="Feature_Format"                defaultvalue="File Geodatabase - GDB - .gdb"                label="3. Select file format"                required="true"                type="string"                visible="true">             <choicelist>                 <choice value="File Geodatabase - GDB - .gdb"/>                 <choice value="Shapefile - SHP - .shp"/>                 <choice value="Geographic Markup Language - GML - .gml"/>                 <choice value="OpenGIS KML Encoding Standard - OGCKML - .kmz"/>                 <choice value="Autodesk AutoCAD - DXF_R2007 - .dxf"/>                 <choice value="Autodesk AutoCAD - DWG_R2007 - .dwg"/>                 <choice value="Bentley Microstation Design (V8) - DGN_V8 - .dgn"/>             </choicelist>         </param>                  <param name="Raster_Format "                defaultvalue="ESRI GRID - GRID "                label="3. Select file format"                required="true"                type="string"                visible="true">             <choicelist>                 <choice value="ESRI GRID - GRID"/>                 <choice value="File Geodatabase - GDB - .gdb"/>                 <choice value="ERDAS IMAGINE - IMG - .img"/>                 <choice value="Tagged Image File Format - TIFF - .tif"/>                 <choice value="Graphic Interchange Format - GIF - .gif"/>                 <choice value="Joint Photographics Experts Group - JPEG - .jpg"/>                 <choice value="Joint Photographics Experts Group - JPEG 2000 - .jp2"/>             </choicelist>         </param>              </inputparams>          <outputparams>         <param name="Output_Zip_File "                label="Output Zip file"                required="true"                type="datafile"                visible="true"/>     </outputparams>     <layerorder>Area_of_Interest</layerorder>     <labels>         <submitlabel>Extract</submitlabel>     </labels> </configuration>

my problem is that during the execution of the project nothing happens the widget does not work and no error message!!
what I can do??? help me please.
[ATTACH=CONFIG]31891[/ATTACH]
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
BjornSvensson
Esri Regular Contributor
I test the browser on the same machine as has the GP task.but how I can change the actual server name?

As long as you're testing only on the same machine, then "localhost" should work ok (for now). But if (or when) you want someone to use your application from their own machines, you will need to edit the configuration files that have "localhost" in them. So usually it's a good practice to not reference "localhost".

what I want is to run this  geoprocessing widget from a model published as a geoprocessing service.

That picture looks more like the "Data Extract" widget than the Geoprocessing widget.  Did you try with the Data Extract widget? 

Are you using the application builder to create your application?

View solution in original post

0 Kudos
4 Replies
BjornSvensson
Esri Regular Contributor
If you are using the data extract GP task, then you might want to use the "Data Extract Widget" that was set up specifically for this case:
http://resources.arcgis.com/en/help/flex-viewer/concepts/index.html#/Data_Extract_widget/01m30000003...

However, if the problem is with the GP task itself, that will not fix anything. 

Some things you might want to try:

  • Are you testing the browser on the same machine as has the GP task?  If not, "localhost" in the config file will not work.

  • Even if you do, it's a good idea to change the "localhost" to the actual server name sooner than later.

  • If you look at the network traffic using browser developer tools (depending on which browser you use), are there any "red" items?

0 Kudos
fatizanady
Deactivated User
hi bjorn,
Firstly thank you for interest in my question.
I test the browser on the same machine as has the GP task.but how I can change the actual server name???? I'm sorry for this stupid question :(.
what I want is to run this  geoprocessing widget from a model published as a geoprocessing service.lik this:
[ATTACH=CONFIG]31893[/ATTACH]
0 Kudos
BjornSvensson
Esri Regular Contributor
I test the browser on the same machine as has the GP task.but how I can change the actual server name?

As long as you're testing only on the same machine, then "localhost" should work ok (for now). But if (or when) you want someone to use your application from their own machines, you will need to edit the configuration files that have "localhost" in them. So usually it's a good practice to not reference "localhost".

what I want is to run this  geoprocessing widget from a model published as a geoprocessing service.

That picture looks more like the "Data Extract" widget than the Geoprocessing widget.  Did you try with the Data Extract widget? 

Are you using the application builder to create your application?
0 Kudos
fatizanady
Deactivated User
I have already used the data extactwidget.
But,what I want is to consume a geoprocessing service (in my case it is a builder model , in which I defined paramettres) in my application flex.Now I tried to do a test with  Geoprocessing Widget:ExtractData.
for that I followed this tutorial :http://resources.arcgis.com/en/help/main/10.1/index.html#//005700000073000000 ,to publish a map service and a geoprocessing service,now i want to know how to consume that in my flex projet.
i use: ArcGIS Desktop 10.1, arcgis server 10.1 flex viewer 3.4 eclipce.

Tanks very much bjorn 🙂
0 Kudos