Hi, relatively new to scripting. I have been able to get a basic script working from a batch file but cannot find any information on using some sort of logic within the script. I.e
result=open session
IF(NOT(ISEQUAL(result,"OK")))
CALL(blat_cmd_line1)
SLEEP(5)
EXIT(1)
END IF
Thanks, I have made some progress and am using a batchfile in conjunction with a script. Is it possible to step in and out of a single script from a batch file or would I have to use multiple script files if I want / need to go back and forth from the batch file.
Martin, This batch script works but when I break it down to more than 1 command block I can't get it to work. If I can sort this out then the error reporting can be much better.
This Works
____________________________________________________
@echo off
set cmdopen=open tester
set cmdbatchon=option batch on
set cmdconfirmoff=option confirm off
set cmdgetaudio=get /uploads/*.DSS /uploads/*.dss /uploads/*.WAV /uploads/*.wav /uploads/*.MP3 /uploads/*.mp3 C:\QSDU\Uploads\*.*
set cmdmvaudio=mv /uploads/*.DSS /uploads/*.dss /uploads/*.WAV /uploads/*.wav /uploads/*.MP3 /uploads/*.mp3 /uploads/wsArchive/*.*
set cmdgetinc=get /incomplete_reports/*.doc C:\QSDU\incomplete_reports\*.doc
set cmdmvinc=mv /incomplete_reports/*.doc /incomplete_reports/wsArchive/*.doc
set cmdputfiles=put C:\QSDU\temp\*.* /completed_reports/2007/*.*
set logpath="C:\Program Files\WinSCP\ots_scripts\logs\qsdu.log"
echo running winscp commands
winscp.exe /command "%cmdopen%" "%cmdbatchon%" "%cmdconfirmoff%" "%cmdgetaudio%" "%cmdmvaudio%" "%cmdgetinc%" "%cmdmvinc%" "%cmdputfiles%" "exit" /log=%logpath%
if errorlevel 1 goto error1
echo WinSCP commands run successfully ...
pause
exit
:error1
echo Error Level 1 Reported
pause
exit__________________________________________________________________