TRANSFER.BAT

The contents of the BAT file are shown in red; a discussion of what that code does is shown in black.

@echo off



:START

  opsys=

  cls

  echo .

  set drive=%1

  if "drive"=="" goto FINDDRIVE

  if not exist %drive%:\NUL goto FINDDRIVE

  goto GOTDRIVE



:FINDDRIVE  

  strings drive=ask Enter TARGET drive letter & press ENTER ,1

Use strings.com to capture target drive. If you don't have the strings program it is available here




:GOTDRIVE  

  if not exist %drive%:\NUL goto NODRIVE

  md %drive%:\install

  md %drive%:\installed

  copy htwall.bmp %drive%:\install

  copy htwall2.bmp %drive%:\install

  echo Image will be installed on %drive%:\

Once we have identified the drive to copy things to, we create two directories on that drive (install and installed), we copy two different HelpingTulsa wallpapers to the install folder.

The BAT file loops displaying the types of transfers that can be requested, until the user enters X to exit from the loop. The choice program prompts for a character to be entered, and then it sets the errorlevel based on the character entered. You should see the choice program in your Dos disk, but if you can't find it, it is here


:LOOP

  echo .

  echo               (1)Operating System Image

  echo               (2)Bible Programs

  echo               (3)Game Programs

  echo               (4)Internet Programs

  echo               (5)Office Suites

  echo               (6)Utility Programs

  echo .

  echo               (X)Exit

  echo .

  echo          ****Press number to choose image****



  choice /c:12345678X /n

   if errorlevel 9 goto END

   if errorlevel 8 goto 8

   if errorlevel 7 goto 7

   if errorlevel 6 goto 6

   if errorlevel 5 goto 5

   if errorlevel 4 goto 4

   if errorlevel 3 goto 3

   if errorlevel 2 goto 2

   if errorlevel 1 goto 1

   goto NOT

Call IMAGES.BAT to transfer the requested operating system files


:1

  call IMAGES.BAT %drive% transfer

  set opsys=%drive%

  goto LOOP

Call BIBLE.BAT to transfer Bible programs


:2

  call BIBLE.BAT %drive% transfer

  goto LOOP

Call GAMES.BAT to transfer game programs


:3

  call GAMES.BAT %drive% transfer

  goto LOOP

Call NET.BAT to transfer internet related programs


:4

  call NET.BAT %drive% transfer

  goto LOOP

Call SUITE.BAT to transfer office suite programs


:5

  call SUITE.BAT %drive% transfer

  goto LOOP

Call UTIL.BAT to transfer utility programs


:6

  call UTIL.BAT %drive% transfer

  goto LOOP



:7

  goto LOOP



:8

  goto LOOP

Call to transfer Cab Files


:COPYCAB

     md %drive%:\%whatcab%

     copy \%whatcab%\*.* %drive%:\%whatcab%  

     goto END 



:NODRIVE

  echo Drive not found, cannot continue

  pause

  goto exit



:NOT

  echo File CHOICE.COM not found, cannot continue

  echo .

  goto exit


:END

  if opsys=="" goto CLEAR

  cls

  echo .

  echo DONE!!

  echo .

  echo Install the new drive as the C: in a system. Remove any disk

  echo from the A: drive and reboot the system.

  echo If the system does not boot, you should boot from a floppy 

  echo containing the operating system of the image and use the

  echo SYS C: command to make the drive bootable.

:CLEAR

  set opsys=

  set drive=

  set cab=

  set whatcab=



:exit