0

Find and access subfolders



I'm thinking of getting a BrightSign HD2000. I've started looking thru the scripting documentation and it seems like it's able to do pretty much everything I would need it for, however, I just have a question or two that would really help me to decide if I should proceed with the purchase.

I have several thousand images spread across several dozen folders and subfolders. I'm wondering if it's possible to use the ListDir command to find subfolders. For example the list that ListDir returns, will it include only files or also subfolder names? Cause if it also includes subfolder names I'm assuming I could filter out anything with an extension and be left with only subfolder names. Then I pass the subfolder name to the ListDir command and get the contents of the subfolder and start over to check if the subfolder has subfolders itself.

Alternatively, is it possible to load a text file that would contain only folder paths, and then pass each line of the file to the ListDir command to get a list of contents of each folder?

Thanks,
Harry

1 comment

  • 0
    Avatar
    RokuLyndon


    The second option makes the most sense. You can read in a text file, and pass the lines, that includes the path that you want to get a list from. Listdir only returns file names.
Please sign in to leave a comment.