I am creating a very simple python script tool in ArcGIS Pro to allow the user to list the layer files in a folder and perform a multiple select to add to the Map of their choice. My problem is the input parameter in the script tool has a dependency set on the folder that the user specifies to look first for layer files, but the browse dialog just keeps bringing up the project workspace folder instead of the user-specified folder. Is anyone else having difficulty creating a simple list of files within a user-specified folder?
Solved! Go to Solution.
Update: An incident was started with ESRI for this. They said even though this previously worked in ArcMap, it wasn't supposed to be supported according to ArcMap documentation. So they will not support it in ArcGIS Pro, and listed it as a bug that Folder is listed as a supported dependency.
BUG-000113274 - ArcGIS Pro lets you select a dependency for parameters, even when the input data type does not support dependencies.
Update: An incident was started with ESRI for this. They said even though this previously worked in ArcMap, it wasn't supposed to be supported according to ArcMap documentation. So they will not support it in ArcGIS Pro, and listed it as a bug that Folder is listed as a supported dependency.
BUG-000113274 - ArcGIS Pro lets you select a dependency for parameters, even when the input data type does not support dependencies.
Esri says ArcMap documentation also does not support Folder dependency from Layers. Could be that the current folder was set instead, making it appear that a dependency could be made.
We will likely just connect to the specific Layers folder from Folders in the Catalog, where users can drag and drop layers of their choice to the map.