hi all,
i hv written the script for file transfer when i am trying to transfer the file on windows machine only same desktop from one location to another location that is working fine but when i am trying to transfer the same to unix server it is going in infinte loop and file is also not getting transfer. And i am not able define the variable also for transferring the file pls assist on the below code :-
setlocal enabledelayedexpansion
if exist C:\Ripudaman\VCB\FTP\*.txt (goto COPYFILES) else (goto NOFILES)
:COPYFILES
for /f %%i in ('DIR /b C:\Ripudaman\VCB\FTP\*.txt') do (
echo %%i
set fn=%%i
ftp
o 172.16.2.97
finacle
7018finacle
mput $i
bye
move %%i C:\Ripudaman\VCB\FTP\bkup\.
)
echo complete
:NOFILES
echo There are no files to move
any help will be appreciated.
---------- Post updated at 06:32 AM ---------- Previous update was at 04:06 AM ----------
much clarification on the issue i am trying to transfer the file from windows to unix where mput is not working appropriately. i hv declare the variable i which is my files in the given directory and it is not transferring to unix system.
ftp isn't going to "eat" the lines below it. To feed lines into ftp, you'll have to feed lines into ftp. Try writing them into a file first, then ftp < input.txt