/[james]/archive/linkcrunch/Join
ViewVC logotype

Contents of /archive/linkcrunch/Join

Parent Directory Parent Directory | Revision Log Revision Log


Revision 31 - (show annotations) (download)
Thu Sep 25 17:13:56 2003 UTC (21 years, 1 month ago) by james
File size: 930 byte(s)
Initial import.

1 REM > Join
2 REM Š James Bursa, 1997
3
4 DIM B% 255
5
6 SYS"OS_GetEnv" TO Envi$
7 IF LEFT$(Envi$, 12) = "BASIC -quit " THEN Envi$ = MID$(Envi$, 13)
8 IF INSTR(Envi$, " ") = 0 THEN ERROR 0, "Syntax: Join <main program> <appended file>"
9 Envi$ = MID$(Envi$, INSTR(Envi$, " ") + 1)
10 IF INSTR(Envi$, " ") = 0 THEN ERROR 0, "Syntax: Join <main program> <appended file>"
11 Main$ = LEFT$(Envi$, INSTR(Envi$, " ") - 1)
12 File$ = MID$(Envi$, INSTR(Envi$, " ") + 1)
13
14 SYS"OS_File", 17, Main$ TO Type%,,,, Siz1%
15 IF Type% <> 1 THEN ERROR 0, "Join: File " + Main$ + "‘ not found"
16 SYS"OS_File", 17, File$ TO Type%,,,, Siz2%
17 IF Type% <> 1 THEN ERROR 0, "Join: File " + File$ + "‘ not found"
18
19 PRINT "Join: "+Main$+" ("+STR$Siz1%+") + "+File$+" ("+STR$Siz2%+")"
20
21 END = END + (Siz1% + Siz2%) + 1024
22 DIM File% (Siz1% + Siz2%)
23
24 SYS"OS_File", 16, Main$, File%
25 SYS"OS_File", 16, File$, File% + Siz1% - 2
26 SYS"OS_File", 10, Main$, &FFB,, File%, File% + Siz1% + Siz2% - 2

  ViewVC Help
Powered by ViewVC 1.1.26