Syncfile with subfolders

Discussions about syncing data via Bluetooth, Dropbox, FTP, and using CSWeb
Forum rules
New release: CSPro 8.0
Post Reply
Harry
Posts: 20
Joined: June 17th, 2021, 7:16 pm
Location: Costa Rica

Syncfile with subfolders

Post by Harry »

Dear all,

I want to download from a FTP server the files from a folder, including all subfolders on it, but syncfile function does not have a parameter for that (like recursive of dirlist function). I can not do a syncfile function calls for each subfolder because I do not know before hand the subfolders names to download. Someone has a idea how to do it?

Kind regards

Harry
Gregory Martin
Posts: 1777
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: Syncfile with subfolders

Post by Gregory Martin »

Using current CSPro functionality, there is no way to get a server's directory listing.

Could you restructure your program so that all files go in the same directory? With the proper file naming scheme, you could use syncfile with a universe to restrict what files are downloaded at any particular point.
Harry
Posts: 20
Joined: June 17th, 2021, 7:16 pm
Location: Costa Rica

Re: Syncfile with subfolders

Post by Harry »

Thanks Gregory for your answer.
I thing the solution is to put in the server a zip file with all the files and subfolders inside.

Cheers,
Harry
Post Reply