FTPLOGON "ftp.mysite.com" /user=myusername /pw=mypassword FTPGETFILE "*.exe" IFERROR GOTO done RCVFILE %sitefile /delete FTPLOGOFF SET full_path = %currentlocaldir + "\" + %sitefile SET cmdline = 'C:\VirusCL\scan "' + full_path + '"' DOSCMD cmdline /timeout=90 IFNUM= %lasterror 0 GOTO done CONSOLEMSG "Problem found!" ; Add code here to handle problem file :done STOP