home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C64'er
/
C64'er.iso
/
85xx
/
8512.d64
/
lit.verw.
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
1995-03-30
|
8KB
|
288 lines
10 REM *******************************
15 REM * *
20 REM * LITERATUR VERWALTUNG *
25 REM * *
30 REM * DEMOPROGRAMM *
35 REM * ZU SMU *
40 REM * *
45 REM * AUTOR: GEORG KRCAL *
50 REM * *
60 REM * ZIEGELHOFSTRASSE 36/11/9 *
65 REM * A-1220 WIEN *
70 REM * TELEFON: 22-17-724 *
75 REM * *
80 REM *******************************
100 IFA=0THENPOKE56,144:CLR:A=1:LOAD"SMUBU",8,1
110 CLR:SYS9*4096
120 PRINTCHR$(147)CHR$(8)CHR$(14)CHR$(30);
130 POKE53280,0:POKE53281,0
140 DIM M$(14),H$(20)
150 REM
160 !MASK "ZEITSCHRIFT",8,M$(0)
170 FORI=1TO40:CD$=CD$+CHR$(17)
180 CR$=CR$+CHR$(29):BL$=BL$+" ":NEXT
190 CD$=CHR$(19)+CD$:X=FRE(0)
200 RI$=CHR$(18):RO$=CHR$(146)
210 B1$=RI$+"1"+RO$+" EINGEBEN "+RI$+"3"+RO$+" SUCHEN "+RI$+"5"+RO$
220 B1$=B1$+" WEITER "
230 B2$=RI$+"2"+RO$+" DRUCKEN "
240 B2$=B2$+RI$+"4"+RO$+" INDEX "+RI$+"6"+RO$+" PRG-ENDE"
300 PRINT"[196]ISKETTE FORMATIEREN [J/N]";:WAIT 203,63
310 GETG$:IFG$<>"J"THEN380
320 PRINTG$"A":PRINT"[196]ISKETTENNAME:"
330 PRINT"[196]ISKETTEN - [201][196]":!INLINE 1,15,16,DN$
340 !INLINE2,16,2,DI$:IFDI$=" "THEN340
350 H$="N:"+DN$+","+DI$:PRINT:PRINT" [196]ISKETTE EINLEGEN - [212]ASTE DRUECKEN"
360 GETG$:IFG$=""THEN360
370 REM "OPEN 1,8,15,H$:CLOSE1"
380 PRINTCHR$(147)"[194]ESTEHENDE [196]ATEI [J/N] ?"
390 WAIT203,63:GETG$:IFG$="J"THEN500
400 IFG$<>"N"THEN390
410 OPEN1,8,2,"LITERATUR,L,"+CHR$(202)
420 GOSUB10000
440 OPEN2,8,15
450 PRINT#2,"P"+CHR$(2)+CHR$(44)+CHR$(1)+CHR$(1)
460 PRINT#1,CHR$(255)
470 PRINT#2,"P"+CHR$(2)+CHR$(1)+CHR$(1)+CHR$(1)
480 PRINT#1,1,CHR$(13);1;CHR$(13);1
490 CLOSE2:CLOSE1
500 GOSUB10000:OPEN1,8,2,"LITERATUR,L,"+CHR$(202)
510 OPEN2,8,15
520 PRINT#2,"P"+CHR$(2)+CHR$(1)+CHR$(1)+CHR$(1)
530 INPUT#2,EN,EN$,T,S:IFENTHENCLOSE1:CLOSE2:GOSUB10070:GOTO500
540 INPUT#1,LR,SE,AE:CLOSE2:CLOSE1
550 TS=SE+100:TA=AE+100
580 DIMS$(SE+100),AU$(AE+100),SL$(SE+100),SH$(SE+100),AL$(AE+100),AH$(AE+100)
590 IFSE=1THEN680
600 OPEN1,8,2,"STICHWORT,S,R":OPEN2,8,15:INPUT#2,EN,EN$,T,S
610 IFENTHENCLOSE1:GOSUB10070:GOTO600
620 FORI=1TOSE-1:INPUT#1,S$(I)
625 GOSUB7300:SL$(I)=H$:SH$(I)=H1$
630 NEXTI:CLOSE2:CLOSE1
640 OPEN1,8,2,"AUTOR,S,R"
650 REM IFENTHENCLOSE1:GOSUB10070:GOTO640
660 FORI=1TOAE-1:INPUT#1,AU$(I)
665 GOSUB7300:AL$(I)=H$:AH$(I)=H1$
670 NEXTI:CLOSE1
680 PRINT"[147]":GOSUB10030
700 !SCREEN M$(0)
710 GOSUB10040
720 !IMASK "[133][134][135][137][138][139]",S$,T1$,T2$,T3$,T4$,AU$,V1$,V2$,O$,JA,SE$,B$,AN,Z1$,Z2$
725 GOSUB10000
730 ONPEEK(2)GOTO740,1100,1000,1200,720,2000,720
740 IFSE+1>TSTHENPRINT"STICHWORTDATEI ZU GROSS":STOP
750 GOSUB7000:IFLEN(SL$(EI+1))>255THENPRINT"STICHWORTTABELLE ZU GROSS":STOP
760 IFGE=1THENH1=I:GOTO780
770 H1=EI+1:SE=SE+1:H3$="":H4$=""
772 FORI=EI+1TOSE:H$=S$(I):S$(I)=S$:S$=H$
773 H1$=SL$(I):SL$(I)=H3$:H3$=H1$:H2$=SH$(I):SH$(I)=H4$:H4$=H2$
775 NEXTI
780 IFAE+1>TATHENPRINT"AUTORENDATEI ZU GROSS":STOP
790 GOSUB7100:IFLEN(AL$(EI+1))>255THENPRINT"AUTORENTABELLENUEBERLAUF":STOP
800 IFGE=1THENEI=I-1:GOTO820
810 AE=AE+1:H3$="":H4$=""
812 FORI=EI+1TOAE:H$=AU$(I):AU$(I)=AU$:AU$=H$
813 H1$=AL$(I):AL$(I)=H3$:H3$=H1$:H2$=AH$(I):AH$(I)=H4$:H4$=H2$:NEXT
820 LR=LR+1:H=LR:GOSUB7200
830 SH$(H1)=SH$(H1)+CHR$(HB):SL$(H1)=SL$(H1)+CHR$(LB)
840 AH$(EI+1)=AH$(EI+1)+CHR$(HB):AL$(EI+1)=AL$(EI+1)+CHR$(LB)
845 REM GOSUB 11000:LR=LR+1:GOTO700
850 OPEN1,8,2,"LITERATUR,L,"+CHR$(202)
860 OPEN2,8,15
870 PRINT#2,"P"+CHR$(2)+CHR$(LB)+CHR$(HB)+CHR$(1)
880 H$=T1$+T2$+T3$+T4$+V1$+LEFT$(V2$,10):PRINT#1,H$
890 LR=LR+1:LB=LB+1:IFLB=256THENLB=0:HB=HB+1
900 PRINT#2,"P"+CHR$(2)+CHR$(LB)+CHR$(HB)+CHR$(1)
910 H3$=RIGHT$(V2$,28)+O$
920 H$=STR$(JA):GOSUB7210:H1$=H$+LEFT$(BL$,(4-LEN(H$)))
930 H$=STR$(AN):GOSUB7210:H2$=H$+LEFT$(BL$,(2-LEN(H$)))
940 H$=H3$+H1$+SE$+B$+H2$+Z1$+Z2$+AU$(EI+1)+S$(H1):PRINT#1,H$
999 CLOSE2:CLOSE1:GOTO700
1000 WE=1:GOSUB8000:IFWE=0THEN730
1010 GOTO710
1100 OPEN4,4,7:GOSUB10000:GOSUB7900:CLOSE4:GOTO710
1200 S1=1:OPEN4,4,7:PRINT#4,CHR$(13)CHR$(13)CHR$(13)
1220 PRINT#4,CHR$(14);"[211][212][201][195][200][215][207][197][210][212][197][210]";CHR$(15);CHR$(13);CHR$(13)CHR$(13)
1230 FORI=1TOSE-1:FORJ=1TO20:H$(J)=" ":NEXT
1240 H$=S$(I):GOSUB7210:H$(1)=H$+": "
1250 Z=1:FORJ=1TOLEN(SL$(I))
1260 H=ASC(MID$(SL$(I),J,1)):H1=ASC(MID$(SH$(I),J,1))
1270 H$=STR$((H+H1*256)/2):GOSUB7210:H$=H$+","
1280 IFLEN(H$(Z))+LEN(H$)>79THENZ=Z+1
1290 H$(Z)=H$(Z)+H$:NEXT
1300 H$(Z)=LEFT$(H$(Z),(LEN(H$(Z))-1))
1310 FORJ=1TOZ:PRINT#4,H$(J)
1315 NEXTJ
1320 NEXTI
1330 PRINT#4,CHR$(13)CHR$(13)CHR$(13)
1340 PRINT#4,CHR$(14)"[193][213][212][207][210][197][206]"CHR$(15)CHR$(13)CHR$(13)CHR$(13)
1350 FORI=1TOAE-1:FORJ=1TO20:H$(J)=" ":NEXT
1360 H$=AU$(I):GOSUB7210:H$(1)=H$+": "
1370 Z=1:FORJ=1TOLEN(AL$(I))
1380 H=ASC(MID$(AL$(I),J,1)):H1=ASC(MID$(AH$(I),J,1))
1390 H$=STR$((H+H1*256)/2):GOSUB7210:H$=H$+","
1400 IFLEN(H$(Z))+LEN(H$)>79THENZ=Z+1
1410 H$(Z)=H$(Z)+H$:NEXT
1420 H$(Z)=LEFT$(H$(Z),(LEN(H$(Z))-1))
1430 FORJ=1TOZ:PRINT#4,H$(J)
1440 NEXTJ
1450 NEXTI
1460 PRINT#4,CHR$(13)CHR$(13)CHR$(13)
1470 PRINT#4,CHR$(14)"[204][201][212][197][210][193][212][213][210][211][212][197][204][204][197][206]"CHR$(15)CHR$(13)CHR$(13)CHR$(13)
1480 FORI=2TOLR-1STEP2
1490 H=I:GOSUB7200:GOSUB9000:GOSUB7400
1510 H$=STR$(I/2):GOSUB7210:H$="("+H$+")"
1520 H$=H$+LEFT$(BL$,(9-LEN(H$)))+H$(1):PRINT#4,H$
1530 FORJ=2TOZ:PRINT#4,SPC(9);H$(J):NEXT
1550 NEXTI
1560 CLOSE4:GOTO710
2000 OPEN1,8,15,"S:STICHWORT":CLOSE1
2010 OPEN1,8,2,"STICHWORT,S,W"
2020 FORI=1TOSE-1:H$=CHR$(34)+S$(I)+CHR$(34):PRINT#1,H$
2030 FORJ=1TOLEN(SL$(I)):G=ASC(MID$(SL$(I),J,1))
2040 PRINT#1,G
2052 G=ASC(MID$(SH$(I),J,1)):PRINT#1,G:NEXT
2054 PRINT#1,"++":NEXTI
2060 CLOSE1
2070 OPEN1,8,15,"S:AUTOR":CLOSE1
2080 OPEN1,8,2,"AUTOR,S,W"
2090 FORI=1TOAE-1:H$=CHR$(34)+AU$(I)+CHR$(34):PRINT#1,H$
2100 FORJ=1TOLEN(AL$(I)):G=ASC(MID$(AL$(I),J,1))
2110 PRINT#1,G
2122 G=ASC(MID$(AH$(I),J,1)):PRINT#1,G:NEXT
2130 PRINT#1,"++":NEXTI:CLOSE1
2140 OPEN1,8,2,"LITERATUR,L,"+CHR$(202)
2150 OPEN2,8,15
2160 PRINT#2,"P"+CHR$(2)+CHR$(1)+CHR$(1)+CHR$(1)
2170 H$=STR$(LR)+CHR$(13)+STR$(SE)+CHR$(13)+STR$(AE)
2180 PRINT#1,H$
2200 CLOSE2:CLOSE1
2210 PRINT"[147]";:END
7000 LI=SE:EI=0:I=0:GE=0
7010 IF((LI-EI)/2)<1THENRETURN:REM STICHWORT NICHT VORHANDEN
7020 I=INT((LI-EI)/2)+EI
7030 IFS$(I)=S$THENGE=1:RETURN
7040 IFS$<S$(I)THENLI=I:GOTO7010
7050 EI=I:GOTO7010
7100 LI=AE:EI=0:I=0:GE=0
7110 IF((LI-EI)/2)<1THENRETURN:REM AUTOR NICHT VORHANDEN
7120 I=INT((LI-EI)/2)+EI
7130 IFAU$(I)=AU$THENGE=1:RETURN
7140 IFAU$<AU$(I)THENLI=I:GOTO7110
7150 EI=I:GOTO7110
7200 HB=INT(H/256):LB=H-HB*256:RETURN
7210 FORII=LEN(H$)TO1STEP-1:IFMID$(H$,II,1)=" "THENNEXT
7220 H$=LEFT$(H$,II):FORII=1TOLEN(H$):IFMID$(H$,II,1)=" "THENNEXT
7230 H$=RIGHT$(H$,(LEN(H$)-II+1)):RETURN
7300 H1$="":H$="":FORJ=1TO256:INPUT#1,G$:IFG$="++"THENJ=256:RETURN
7305 IFG$="0 "THENH$=H$+CHR$(0):GOTO7315
7310 H$=H$+CHR$(VAL(G$))
7315 INPUT#1,G$
7320 IFG$="0 "THENH1$=H1$+CHR$(0):GOTO7340
7330 H1$=H1$+CHR$(VAL(G$))
7340 NEXTJ:RETURN
7400 FORL=1TO10:H$(L)="":NEXT
7405 IFAU$=LEFT$(BL$,25)THENAU$="?"
7410 H$=AU$:GOSUB7210:H$(1)=H$+":"
7420 IFT1$=LEFT$(BL$,38)THENT1$="?"
7430 H$=T1$:GOSUB7210:H$(2)=H$+" ":Z=1
7440 IFT2$=LEFT$(BL$,38)THEN7500
7450 H$=T2$:GOSUB7210:H$(2)=H$(2)+H$+" "
7460 IFT3$=LEFT$(BL$,38)THEN7500
7470 Z=2:H$=T3$:GOSUB7210:H$(3)=H$+" "
7480 IFT4$=LEFT$(BL$,38)THEN7500
7490 H$=T4$:GOSUB7210:H$(3)=H$(3)+H$
7500 Z=Z+1:H$(Z)=H$(Z)+"."
7510 IFB$="N"ORB$="[206]"THEN7660
7520 Z=Z+1:IFO$=LEFT$(BL$,34)THENO$="?"
7530 H$=O$:GOSUB7210:H$(Z)=H$(Z)+H$
7540 IFV2$=LEFT$(BL$,38)THENH$="":GOTO7560
7550 H$=V2$:GOSUB7210
7560 IFLEN(H$(Z))+LEN(H$)+2>70THENZ=Z+1
7570 H$(Z)=H$(Z)+H$+", "
7580 IFJA=0THENH$="?":GOTO7600
7590 H$=STR$(JA):GOSUB7210
7600 IFLEN(H$(Z))+LEN(H$)+2>70THENZ=Z+1
7610 H$(Z)=H$(Z)+H$+", "
7620 IFSE$=LEFT$(BL$,10)THENH$="":GOTO7650
7630 H$=SE$:GOSUB7210
7640 IFLEN(H$(Z))+LEN(H$)+1>70THENZ=Z+1
7650 H$(Z)=H$(Z)+H$+".":RETURN
7660 Z=Z+1:IFZ1$=LEFT$(BL$,38)THENH$="?"
7670 H$=Z1$:GOSUB7210:H$(Z)=H$(Z)+H$+" "
7680 IFZ2$=LEFT$(BL$,38)ORH$="?"THENH$="":GOTO7700
7690 H$=Z2$:GOSUB7210
7700 IFLEN(H$(Z))+LEN(H$)+1>70THENZ=Z+1
7710 H$(Z)=H$(Z)+H$+" "
7720 IFAN=0THENH$="?":G