Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!pasteur!ucbvax!tut.cis.ohio-state.edu!osu-cis!att!cbnewsh!mbb From: mbb@cbnewsh.ATT.COM (martin.b.brilliant) Newsgroups: comp.sys.ibm.pc Subject: Re: Why CTRL-2 and CTRL-6 and not others??? Message-ID: <223@cbnewsh.ATT.COM> Date: 21 Apr 89 01:40:01 GMT References: <1673@blake.acs.washington.edu> Organization: AT&T Bell Laboratories Lines: 33 From article <1673@blake.acs.washington.edu>, by djo7613@blake.acs.washington.edu (Dick O'Connor): > > OK, keyboard scan experts, here's one for you: > > While playing with macro-building in PC Tools Deluxe's Macro Editor, > I tried all of the -number combinations using the top row number > keys and could only assign CTRL-2 and CTRL-6 as hot-keys. It didn't > seem to recognize the other eight potential CTRL-digit combinations. I bet it has nothing to do with scan codes. I would guess it depends on the definitions of control characters. In the ASCII code table there are 32 control characters with ASCII numeric values of 0 to 31 (decimal). Control characters 1 through 26 are obtained by hitting CTRL-A through CTRL-Z, that is, the CTRL key with the printable character whose ASCII code is 64 plust the code for the control character. That leaves 6 control characters to be based on non-alphabetic printable characters. The character preceding A is @ and so CTRL-@ is the 0 control character, but since @ is SHIFT-2 you get it with CTRL-2 (to make it easier, CTRL-SHIFT-2 is not required). The others are based on the characters next five after Z in the ASCII code table, most of which can be typed without the SHIFT key. The exceptions are ^ which is SHIFT-6, so you get CTRL-^ by typing CTRL-6, and _ which is SHIFT-minus so you would probably get CTRL-_ by hitting CTRL-minus. M. B. Brilliant Marty AT&T-BL HO 3D-520 (201) 949-1858 Holmdel, NJ 07733 att!cbnewsh!mbb or mbb@cbnewsh.ATT.COM Disclaimer: Opinions stated herein are mine unless and until my employer explicitly claims them; then I lose all rights to them.