Hi all,
I am not sure whether this is possible to do. I would like to upload only picture files from multiple local direcotyr into 1 remote directory. For example:
on local, I have:
c:\mypicture\2001\
c:\mypicture\2002\
c:\mypicture\2003\
c:\mypicture\2004\
Inside 2001, 2002, 2003, 2004 I have all my picture files.
I want to upload all those picture files into 1 remote directory. I have created a ftp login account that will login to the remote directory that I want to upload those picture files to.
So far this is what I have but it does not seems to work.
"C:\Program Files\WinSCP\WinSCP.exe" /script="C:\ftp_auto.txt"
ftp_auto.txt:
open test
option batch on
option confirm off
option include *.bmp;*.jpg;*.gif;*.png
synchronize remote "c:\mypicture\*\" "/"
exit
After upload, the remote directory should have:
picture1.jpg
picture2.jpg
picture3.jpg
picture4.jpg
No subdirectories under this directory should be created. Meaning that I do not want to have:
2001\picture1.jpg
2001\picture2.jpg
2002\picture3.jpg
2002\picture4.jpg
If inside directory 2001 and 2002 contain files with the same name, then only the latest one should be copied to the remote directory.
Any help would be greatly appreciated.
Thanks.
Regards,
AL