Hey everyone!
I've been working on a custom geoprocessing tool.
Users select one or multiple polygon features from the map widget using either a Filter widget or using the Select tool in the map widget. The idea is for the filtered features to be an input parameter in the custom geoprocessing tool-- the filtered records are used to build a query for a database on our server. However, while the filters SEEM to work (the count of features for the layer reflect what's visible in the map widget with the selections/filters applied), the filters DON'T actually apply -- it's not passing the filtered information, just the whole feature layer every time.
I've tried the action buttons --> set as analysis input as a workaround, but it doesn't work if the user selects multiple polygons (no pop up comes up, no pop up means, no action buttons, no "set as analysis input" option). For a single polygon, Set As Analysis Input does work, but a large part of the use of the tool is the ability to run analyses for multiple polygons. I've considered trying to replicate what Set Analysis Input does (create an in-memory feature set somewhere once the filters are applied), but I'm not sure that's the right place to start. Alternatively, maybe finding a way to access the query the filter the map and filter widgets generate and using that to build my downstream query?
All I really need is a way to pass information on what records are selected in the map pane to my tool so I can build my query somehow-- I'm confident I can handle the rest. But I'm really stuck on this step!