Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: Download folders and files only where folder contains specific file

Do you want to download only the final.txt? Or all files in the folder that has the final.txt? Btw, you cannot create a folder with a name containing a slash on Windows.
Mattias

Download folders and files only where folder contains specific file

Hi.
Is there a way to check if a file exists in a folder, that I dont know the path to (it is dynamic).
Ie if there are these folders on the FTP

2020/08/27/11/05
2020/08/27/11/10
And in the 2020/08/27/11/05 folder there are a file named final.txt
I want to download the full path localy and create the folders if not exists.

The other folder, 2020/08/27/11/10 does not have a file called final.txt, so this folder I do not want to download.
But I want to delete the folder that do have the final.txt in it.