vbdpss.hlp (Table of Contents; Topic list)
Article Q33034, Example 2
                                                 Contents  Index  Back
─────────────────────────────────────────────────────────────────────────────
                           Knowledge Base Contents  Knowledge Base Index
 
 How to Trap CTRL+C on Standard & Enhanced Keyboard, Example 2
 
 Code Example 2
 --------------
 Use the following steps to execute the examples listed below in
 VBDOS.EXE:
 
 1. From the File menu, choose New Project.
 2. Copy the code example to the Code window.
 3. Press F5 to run the program.
 
 Use the following code to trap a CTRL+C on either keyboard (standard
 or extended):
 
 KEY 18, CHR$(&H4)+CHR$(&H2E)    ' The &H4 is the CTRL Key.
 KEY (18) ON                     ' The &H2E is the C key.
 ON KEY(18) GOSUB ctrlctrap
 10 : GOTO 10
 END
 ctrlctrap:
         PRINT "CONTROL+C Trapped"
         RETURN