1. from files under the root folder of the FTP server to the specified folder
Format: ftp-s:[configuration file] [FTP address]
such as: Ftp-s:c:\vc\ftpconfig.txt 192.168.1.1
Create a batch file: named Test.bat (name can be casually, for easy operation, directly named 1.bat) and then copy the above contents
Ftpconfig.txt's file content is:
TestUser
Test
Get Test.exe C:\ftptest\testdownload.exe
Bye
Explain:
The first two commands are fixed and are user names and passwords.
Get test.exe C:\ftptest\testdownload.exe Download the Test.exe file under the FTP Server root folder to the local C:\ftptest\ directory with the file name Testdownload.exe
Quit quitting
Execute the established batch file, and you will see that the file is automatically downloaded to the file you specified.
2, from the FTP server specified file Plus, download files to the specified folder
Format: ftp-s:[configuration file] [FTP address]
such as: Ftp-s:c:\vc\ftpconfig.txt 192.168.1.1
Create a batch file: name Test.bat and copy the above contents
Ftpconfig.txt's file content is:
TestUser
Test
CD test
Get Test.exe C:\ftptest\testdownload.exe
Bye
Explain:
The first two commands are fixed and are user names and passwords.
CD Open Folder
Get test.exe C:\ftptest\testdownload.exe Download the Test.exe file under the FTP server folder to the local C:\ftptest\ directory with the file name Testdownload.exe
Quit quitting
3. Upload files to the FTP server root directory
Format: ftp-s:[configuration file] [FTP address]
such as: Ftp-s:c:\vc\ftpconfig.txt 192.168.1.1
Create a batch file: name Test.bat and copy the above contents
Ftpconfig.txt's file content is:
TestUser
Test
Put C:\ftptest\testdownload.exe Test.exe
Bye
Explain:
The first two commands are fixed and are user names and passwords.
CD Open Folder
Put C:\ftptest\testdownload.exe test.exe upload the local C:\ftptest\testdownload.exe file to the FTP server named Test.exe
Quit quitting
4, upload files to the FTP server root specified directory
Format: ftp-s:[configuration file] [FTP address]
such as: Ftp-s:c:\vc\ftpconfig.txt 192.168.1.1
Create a batch file: name Test.bat and copy the above contents
Ftpconfig.txt's file content is:
TestUser
Test
CD test
Put C:\ftptest\testdownload.exe Test.exe
Bye
Explain:
The first two commands are fixed and are user names and passwords.
CD Open Folder
Put C:\ftptest\testdownload.exe test.exe upload the local C:\ftptest\testdownload.exe file to the test folder on the FTP server named Test.exe
Quit quitting
Uploading a download file to an FTP server using a batch file