home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 19 / CD_ASCQ_19_010295.iso / vrac / rtape400.zip / GETFILE.SMP < prev    next >
Text File  |  1994-11-10  |  2KB  |  74 lines

  1. @ECHO OFF
  2. REM This is a sample batch file to use an Upload Processor, such as the free
  3. REM copy of VIRULAB included, with RoboTape. This batch file uses VIRULAB
  4. REM and the shareware program GIFTEST, not included but widely available,
  5. REM to scan uploaded files for viruses and GIF dimensions.
  6. REM .
  7. REM Parameters For Calling This Batch File Are...
  8. REM %1 Com Port Number 1 = Com 1....
  9. REM %2 Transfer Protocol x=Xmodem, b=Ymodem, z=Zmodem.
  10. REM %3 Upload Path For This File Area, "Restored Path" In RBCONFIG Program.
  11. REM %4 File Name To Be Uploaded.
  12. REM %5 File Type 0=Self-Extract Or Not An Archive,1=GIF,2=ZIP,3=ARJ,4=LZH,
  13. REM    5=ARC,6=SQZ,7=ZOO. Use This Parameter For Virus Scanners, GIF Checkers,
  14. REM    And Etc....
  15. REM %6 Baud Rate User Is Logged On At
  16. REM .
  17. REM The File UPSTAT.DAT Will Be Shown To The User After A Bad UPLOAD. Use The
  18. REM   Redirection Symbol ">" To Redirect The Echo To This File.
  19. REM .
  20. :LOOP
  21.    DSZ port %1 r%2 %3%4
  22.    if errorlevel 1 goto BAD
  23.    if errorlevel 0 goto CHECK
  24.    goto DONE
  25. :BAD
  26.    echo WARNING: Bad Upload !!! >UPSTAT.DAT
  27.    echo Exiting With Errorlevel 1
  28.    del %3%4
  29.    goto DONE
  30. :CHECK
  31.     if %5 == 7 goto VCHECK
  32.     if %5 == 6 goto VCHECK
  33.     if %5 == 5 goto VCHECK
  34.     if %5 == 4 goto VCHECK
  35.     if %5 == 3 goto VCHECK
  36.     if %5 == 2 goto VCHECK
  37.     if %5 == 1 goto GIFCHECK
  38.     if %5 == 0 goto VCHECK
  39.     goto UPDATE
  40. :VCHECK
  41.     REM  Run Virus Door Here And Check Errorlevels
  42.     VIRULAB %3%4
  43.     if errorlevel 101 goto UPDATE
  44.     if errorlevel 100 goto UPDATE
  45.     if errorlevel 1 goto BAD
  46.     if errorlevel 0 goto UPDATE
  47.     goto UPDATE
  48. :GIFCHECK
  49.     GIFTEST %3%4 /D /M:320X200X16 /L:GIFSIN.LOG
  50.     if errorlevel 25 goto DUPE
  51.     if errorlevel 20 goto TOOSMALL
  52.     if errorlevel 10 goto LITE
  53.     if errorlevel 1 goto INHEAD
  54.     if errorlevel 0 goto UPDATE
  55.     goto DONE
  56. :LITE
  57.     goto UPDATE
  58. :DUPE
  59.     echo %4 Was A Renamed Duplicate Of A GIF Already On System, REJECTED! >UPSTAT.DAT
  60.     del %3%4
  61.     goto DONE
  62. :TOOSMALL
  63.     echo File Failed The Minimum Resolution Requirement Of 320x200x16, REJECTED! >UPSTAT.DAT
  64.     del %3%4
  65.     goto DONE
  66. :INHEAD
  67.     echo File Had Invalid GIF Header, TRASHED And REJECTED! >UPSTAT.DAT
  68.     del %3%4
  69.     goto DONE
  70. :UPDATE
  71.     goto DONE
  72. :DONE
  73.    echo Exiting Back To Robo Tape.....
  74.