Run Geoprocessing argument required
Hi
I have a workflow that has user select a featureset is parsed into a gptask.
However unsure of expression for argument in the Run Geoprocessing activity.
Featureset: $getFeatureGeometries1.geometries
gptask input parameter: in_features
Also, would the spatial reference (either Out or Process) need to be specified for the activity to work?
Thanks for any help, Vincent
-
The Run Geoprocessing activity takes an argument of type Object:

So you can wrap your featureset in a dictionary:
={'in_features': $getFeatureGeometries1.geometries}
Then you can parse out the key-value pair in_features in your GP task.
The spatial reference argument is not required and will take the default of the input geometries:
0 -
Great thanks Alex. For the noob such as myself could you suggest a site as a starting point on how to generate expressions such as this, trying to work out what is needed is confusing and not sure what they are ( .net /java etc or a combination / or none of the above?) thanks again for your time
0 -
Does this GW5 - Run Geoprocessing (asynchronous) sample help you?
https://www.arcgis.com/home/item.html?id=21c3573546ae485aab66632f9cab9d80
0 -
That is a good example with a relatively complex argument!
The ArcGIS REST API documentation has helped me a lot to understand what is expected of Esri data types with the Javascript SDK https://developers.arcgis.com/javascript/latest/api-reference/ working with feature services https://developers.arcgis.com/rest/services-reference/enterprise/feature-service.htm
I'm not very good at Javascript and it has been a lot of trial-and-error for me to understand the VertiGIS REST API and what it expects, but I have learned stuff and developed "muscle memory" over time.
0 -
Great thanks heaps Nico and Alex, both very useful resources you have provided, cheers.
0 -
Hi
Still getting an error (from browser devtools) when running workflow:
Invalid value for parameter Input Features - Details : Unable to parse JSON value of the parameter.
Referring to Alex comments above:
So you can wrap your featureset in a dictionary:
={'in_features': $getFeatureGeometries1.geometries} - have done this in Run Geoprocessing activity
Then you can parse out the key-value pair in_features in your GP task. -unsure how to do this, see image for my gptask
Thanks, Vincent
1
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
6 Kommentare