BBS: Inland Empire Archive Date: 05-19-92 (08:54) Number: 175 From: MARK BUTLER Refer#: NONE To: JON SPRINGER Recvd: NO Subj: Event trapping Conf: (2) Quik_Bas
On 05-16-92 Jon Springer wrote to All... JS> I am trying to write some code that traps the ctrl_alt_del sequence JS> so when someone enters it, the computer doesn't reboot. There is an JS> example given on page 238 of the Microsoft Qb book, but it only works JS> with the Del key on the numeric keypad, and then only if Num Lock is JS> off. Argh! Could anybody give me some helpful info on this? Plus JS> the scan code for the Break key? (It doesn't appear in the book)... JS> I am at wits end here! Hmmmm, I *hope* this isn't the routine that you've already tried... First set up the control-alt-del trap.... KEY 16, CHR$(12) + CHR$(83) ON KEY(16) GOSUB NoReboot KEY(16) ON ' 'more program code etc. etc. Then when it's needed it goes to... NoReboot: PRINT "No WAY! Ya can't break out of this program THAT easy!" RETURN This works on my machine, hope it helps. -----------> MHB :-) ... OFFLINE 1.36 * Now and then an innocent man is sent to the legislature --- DB B1067/001271 * Origin: * Bare Bones BBS * (1:105/360)
Books at Amazon:
Back to BASIC: The History, Corruption, and Future of the Language
Hackers: Heroes of the Computer Revolution (including Tiny BASIC)
Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution
The Advent of the Algorithm: The Idea that Rules the World
Moths in the Machine: The Power and Perils of Programming
Mastering Visual Basic .NET