This behavior occurs when specifying a file path and not a folder path when using the List Folder VI. This VI expects a valid folder path as input, otherwise, it will throw an error.
To fix this issue you need to change the path to a valid folder path. If you are using a constant you just need to change it to a valid path and if you are using a path control you can follow these steps:
1. Right-click on the path control in the front panel and select Browse Options...
You can also do this by right-clicking on the path control and selecting Properties >> Browse Options
2. Once you are in the Browse Options window go to the Selection Mode panel and select Folders
. This will allow you to select a folder path instead of a file path:
3. Re-run the VI that was throwing the error and save changes if necessary.