Batch File .bat to copy file from File Sharing & FTP Hosting

chacha1234

New member
Local time
3:11 PM
Messages
1
Hi all,

Any idea how to write Batch File .bat to copy file from File Sharing & FTP Hosting to local directory.

Current the File Sharing & FTP Hosting is SMARTFILE.

I don't want to use WINSCP as the connector.

Thanks
 

My Computer My Computer

At a glance

Windows 7 Pro 32 bit
Computer type
PC/Desktop
OS
Windows 7 Pro 32 bit
Hi Chacha,

Give this batch file a try. All text in red, you should adjust before running.

Code:
@echo off
(
	echo.[COLOR="Red"]Username[/COLOR]
	echo.[COLOR="red"]Password[/COLOR]
	echo.lcd [COLOR="red"]C:\Some\local\directory[/COLOR]
	echo.cd [COLOR="red"]/Some/server/path[/COLOR]
	echo.binary
	echo.get [COLOR="red"]Some_file_to_download.txt[/COLOR]
	echo.bye
) > "%TEMP%\_%~n0.ftp"
ftp -s:"%TEMP%\_%~n0.ftp" "[COLOR="Red"]12.34.56.78[/COLOR]"
del "%TEMP%\_%~n0.ftp"
 

My Computer My Computer

At a glance

Windows 10, Windows 8.1 Pro, Windows 7 Profes...
Computer type
PC/Desktop
OS
Windows 10, Windows 8.1 Pro, Windows 7 Professional, OS X El Capitan
Back
Top