我一直在使用以下代码来捕获控制中断,但我没有得到任何回报:
程序执行期间的 Control-Break 会导致以下情况发生:
1)Invokes interrupt trap 1Bh
2)Places 00:00 into keyboard buffer
3)Sets flag 80h at memory 40:71h
检测 Control-Break 的示例(已编译):
DO
X$=INKEY$
IF X$=CHR$(0)+CHR$(0) THEN
PRINT "*break*"
END
END IF
LOOP
检测 Control-Break 的另一个示例(已编译):
DEF SEG = &H40
POKE &H71, 0
DEF SEG
DO
DEF SEG = &H40
X = PEEK(&H71)
DEF SEG
IF X = 128 THEN
PRINT "*break*"
END
END IF
LOOP
有什么我想念的吗?