Remove the line to get room in the memory... you can't. (not easy in Basic)Is there anyway I can remove lines of BASIC whilst the BASIC program is running?
But, if you had to add a trigger on a program, just replace the first binary code to the REM code (234).
Simple code without a REM shadowing:
Code: Select all
10 PRINT "IS THERE ANY ZXPRINTER ONLINE ?"
20 INPUT A$
30 FOR A=1 TO 10
40 PRINT A
50 IF A$(1)="Y" THEN LPRINT A
60 NEXT A
Code: Select all
10 PRINT "IS THERE ANY ZXPRINTER ONLINE ?"
20 INPUT A$
30 LET Z$=""
50 GOSUB 1000
60 POKE PRT,234
70 IF A$(1)="Y" THEN POKE PRT,225
80 FOR A=1 TO 10
90 PRINT A
95 LET Z$=STR$ A
100 GOSUB 1100
110 NEXT A
120 STOP
1000 LET PRT=PEEK 16426*256+PEEK 16425+4
1100 LPRINT Z$
1500 RETURN