
Problem capturing the Tab key in the KeyDown event
What's so special about the <Tab> key that I can't seem to trap it to
assign some special functionality to it in my VB6 program?
I have a form with a Farpoint tab control on it. On that tab control
is another Farpoint tab control. On the second tab control is a
Farpoint list control. In the list control's KeyDown event, I have
some code that executes when various keys are pressed (Tab, PageUp,
PageDown, RightArrow, LeftArrow, various function keys).
Code is executing just fine for Ctrl-Tab and Alt-Tab - in fact, they
all work except for just-plain-Tab-Key. Pressing the Tab key doesn't
even fire the KeyDown event (I put a Stop statement in there to test
it). Pressing <TAB> just moves the focus around to different objects
on the screen.
The form on which these controls reside has its KeyPreview property
set to True.
What am I missing? Why does the Tab key get treated differently?