I need to create an ftp script to from a file list. To create the script to from this list, I need to use the FOR command, but I do not know to use.
List of files is called "verifica.txt" and within it have the lines:
C:\xml\UPLOAD\35150650956911000165550550000198041000464010.doc
C:\xml\UPLOAD\35150650956911000165550550000198051000463983.doc
C:\xml\UPLOAD\35150650956911000165550550000198061000463999.doc
C:\xml\UPLOAD\35150650956911000165550550000198071000464003.doc
C:\xml\UPLOAD\35150650956911000165550550000198081000464027.doc
I am not able to make my script leave the right way. In this code I'm trying to generate my FTP script to put
echo in10xml> upload_files_xml.ftp
echo xml_in10 >> upload_files_xml.ftp
for / f% i in (verifica.txt) echo put% i / content / UPLOAD /% i >> upload_files_xml.ftp
echo bye >> upload_files_xml.ftp
When you run the command FOR above him to give me the result below:
user
password
put C:\xml\UPLOAD\35150650956911000165550550000198041000464010.doc /content/UPLOAD/C:\xml\UPLOAD\35150650956911000165550550000198041000464010.doc
bye
The need FOR generate the result as follows:
user
password
put C:\xml\UPLOAD\35150650956911000165550550000198041000464010.doc /content/UPLOAD/35150650956911000165550550000198041000464010.doc
bye
for /?at a command prompt and see how the/fargument works. And unless you've transported yourself back to the 1990's, this isn't MS-DOS. It's a Windows command prompt..ftpfile , and the error message/ was unexpected at this time.!