home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Beijing Paradise BBS Backup
/
PARADISE.ISO
/
software
/
BBSDOORW
/
FF_200.ZIP
/
FFFTP.ZIP
/
FFFTP
/
GETFILE.CMD
Wrap
OS/2 REXX Batch file
|
1995-08-24
|
1KB
|
67 lines
trace off
/*------------------------------------------------------------------
* load functions, if needed
*------------------------------------------------------------------*/
if RxFuncQuery("FtpLoadFuncs") then
do
rc = RxFuncAdd("FtpLoadFuncs","RxFtp","FtpLoadFuncs")
rc = FtpLoadFuncs()
end
if RxFuncQuery("SysLoadFuncs") then
do
rc = RxFuncAdd("SysLoadFuncs","RexxUtil","SysLoadFuncs")
rc = SysLoadFuncs()
end
/*------------------------------------------------------------------
* set up signal
*------------------------------------------------------------------*/
signal on halt
/*------------------------------------------------------------------
* get parameters
*------------------------------------------------------------------*/
parse arg site user pass ldir rdir file .
say "Start"
/*------------------------------------------------------------------
* set things
*------------------------------------------------------------------*/
rc = FtpSetUser(site,user,pass)
if rc <> 1 then
do
say "Error logon" FTPERRNO
call done
end
rc = FtpChDir(rdir)
if rc <> 0 then
do
say "Error ChDir" FTPERRNO
call done
end
LEFT(ldir,2)
cd ldir
rc = FtpGet(file,file,"BINARY")
if rc <> 0 then
do
say "Error Get" FTPERRNO
call done
end
say "OK"
done:
rc = FtpLogoff()
"C:\HSTART\HWAIT"
exit