home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / INFO / ASMUTL / ASM001.ZIP / UNDOBKUP.BAS < prev   
Encoding:
BASIC Source File  |  1984-01-02  |  2.0 KB  |  37 lines

  1. 10 'UNDOBACK.BAS     UNDO FILES FROM HARD DISK BACKUP COMMAND
  2. 20 KEY OFF:CLS:COLOR 0,7
  3. 30 LOCATE 5,33:PRINT " UNDOBACK.BAS "
  4. 40 LOCATE 7,31:PRINT " By Rich Schinnell ":COLOR 7,0:PRINT:PRINT
  5. 50 PRINT "A program for IBM  DOS 2.0/2.1
  6. 60 PRINT "Fixed Disk owners, ie XT's and expansion chassis's"
  7. 70 PRINT "who use the IBM BACKUP utility on the DOS diskette
  8. 80 PRINT "and want to access files from their backup disks without
  9. 90 PRINT "doing a recover.  The only exception: is a file which was saved part
  10. 100 PRINT "on one disk and part on another.. Sorry about that case ........
  11. 110 PRINT "Maybe some sharper programmer can modify this program to check that"
  12. 120 PRINT "Press <ENTER> to quit   enter ? for dir  (eg..?B:*.* )"
  13. 130 DEFINT A-Z:FALSE=0:TRUE=NOT FALSE:ON ERROR GOTO 330
  14. 140 PRINT:PRINT:INPUT "What is input file name ";INFILE$
  15. 150 IF LEN(INFILE$)<1 THEN 320
  16. 160 IF LEFT$(INFILE$,1)="?" THEN FILES MID$(INFILE$,2):GOTO 140
  17. 170 OPEN INFILE$ FOR INPUT AS #1:CLOSE 1
  18. 180 INPUT "What is output file name ";OUTFILE$
  19. 190 OPEN OUTFILE$ FOR INPUT AS #2:CLOSE 2
  20. 200 PRINT "File ";OUTFILE$;" already exists, try another name please":GOTO 180
  21. 210 OPEN INFILE$ AS #1 LEN=1
  22. 220 FIELD #1,1 AS A$
  23. 230 OPEN OUTFILE$ AS #2 LEN=1
  24. 240 FIELD #2,1 AS B$
  25. 250 A=LOF(1):PRINT "Input file has";A;" Bytes in it"
  26. 260 FOR I=1 TO 128:GET #1:NEXT I
  27. 270 FOR I=129 TO A
  28. 280 GET #1,I:LSET B$=A$
  29. 290 PUT #2:IF (I MOD 50)=0 THEN PRINT CHR$(15);
  30. 300 NEXT I
  31. 310 CLOSE:PRINT:PRINT "File ";OUTFILE$;" Successfully created "
  32. 320 KEY ON:END
  33. 330 IF ERL=170 THEN PRINT "file not found try again ":RESUME 140
  34. 340 IF ERL=190 THEN RESUME 210
  35. 350 PRINT "Error";ERR;" has occured in line #";ERL:RESUME 320
  36.  occured in line #";ERL:RESUME 320
  37.