Hey Everyone,
I published a web tool (based on a python script tool; .atbx, not .pyt) that contains a Feature Layer parameter with a default value, set as constant in the publishing pane (a feature service URL), and a multi-value Field parameter that is dependent on the Feature Layer parameter. This provides a dropdown for users to select fields they want summarized when the tool runs. The problem is that when publishing, this Field parameter is set as a choice list, and the resulting web tool hard-codes those field options into the tool.
My question is, is there a way to publish a tool that does not hard-code the choices and is instead reliant on what layer in the web map a user chooses (if I change how the aforementioned Feature Layer parameter is published)? This is currently being published to Enterprise 10.9.1, so I assume there are likely limitations alleviated in 11.x. I know the Summarize Within Analysis widget tool in Experience Builder allows for this, but that is only in AGOL or 11.x+, so I may just not be able to do it right now.
I can change the Feature Layer parameter to a choice-list as well, but it will just hard-code the layers from the active ArcGIS Pro map. Below is an image of the tools parameters tab showing my current setup.

Best,
Jack C.