home *** CD-ROM | disk | FTP | other *** search
- * Program.: DOS-COPY.PRG
- * Author..: Kelly Mc Tiernan
- * Date....: 12/12/83
- * Notice..: Copyright 1983, Kelly Mc Tiernan, All Rights Reserved.
- * Version.: dBASE II, version 2.4
- * Notes...: Performs a DOS 2.0 COPY function.
- *
- * IN: source-C-63 Pathname of source
- * dest-C-63 Pathname of destination
- * OUT: is:error-L-1 Validation flag
- *
- STORE F TO is:error
- * ---Parameter check.
- STORE !(source) TO source
- STORE !(dest) TO dest
- IF LEN(source) > 63 .OR. LEN(dest) > 63
- * ---DOS 2.0 does not allow paths over 63 chars.
- RETURN
- ENDIF
- * ---POKE the pathnames into memory.
- STORE 1 TO t:counter
- STORE 57088 TO t:address
- DO WHILE t:counter <= LEN(source)
- POKE t:address, RANK($(source,t:counter,1))
- STORE t:address+1 TO t:address
- STORE t:counter+1 TO t:counter
- ENDDO
- POKE t:address,00
- STORE 1 TO t:counter
- STORE 56962 TO t:address
- DO WHILE t:counter <= LEN(dest)
- POKE t:address, RANK($(dest,t:counter,1))
- STORE t:address+1 TO t:address
- STORE t:counter+1 TO t:counter
- ENDDO
- POKE t:address,00
- * -----------0---1---2---3---4---5---6---7---8---9
- POKE 56832, 80, 83, 81, 82,156,137, 38,126
- POKE 56840,222,180, 60,186,130,222,185, 32, 00,205,;
- 33,114, 77,163, 00,224,180, 61,176, 00
- POKE 56860,186, 00,223,205, 33,114, 63,137,195,185,;
- 16, 00,180, 63,205, 33,114, 52, 09,192
- POKE 56880,116, 22,185, 16, 00,180, 64,186, 00,223,;
- 135, 30, 00,224,205, 33,114, 32,135, 30
- * -----------0---1---2---3---4---5---6---7---8---9
- POKE 56900, 00,224,235,221,180, 62,205, 33,114, 20,;
- 135, 30, 00,224,180, 62,205, 33,114, 10
- POKE 56920,139, 38,126,222,157, 90, 89, 91, 88,195,;
- 180, 62,205, 33,135, 30, 00,224,180, 62
- POKE 56940,205, 33,139, 38,126,222,157, 90, 89, 91,;
- 88, 67,198, 07, 69, 00, 75,195
- * -----------0---1---2---3---4---5---6---7---8---9
- SET CALL TO 56832
- STORE " " TO t:flag
- CALL t:flag
- * ---FILE I/O ERROR.
- STORE ( t:flag = "E" ) TO is:error
- RELEASE t:flag,t:counter,t:address
- RETURN
- * EOF: DOS-COPY.PRG