I have a Perl script that uses Tkx::tk___chooseDirectory()
to allow the user to select a directory.
The problem is only a few specific directories are valid for the actions that the script is going to perform. Is there a way to limit the folders displayed by this function to show only folders below a specific subdirectory?
Example:
Say I wanted to only give the user the option to select "Perl64" or any of its subdirectories. How can I force it to hide the other folders (like "PerfLogs" or "Program Files") and only display the valid folders.
I know I can use the -initialdir
option to make it start on "Perl64", but that doesn't hide the other choices.