Arrow Keys, PageUp, PageDn etc. Not Firing KeyDown Event
- From: "Phil Galey" <pagaley@xxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 28 Sep 2005 10:26:59 -0700
I have a Panel control docked on all sides on a form and the panel control
contains a PictureBox. I'm using the KeyDown event of the form to respond to
the [+] and [-] keys for resizing the image and the PageUp, PageDn, Home,
End, and arrow keys for scrolling the Panel control.
Resizing the image using the [+] and [-] keys works fine, deriving a resized
thumbnail from the image and reassigning it to the Image property of the
PictureBox. However I'm running into a problem where the scrolling keys are
placing the form into a state where it suddenly no longer responds to any
keys. KeyDown and KeyPress will no longer fire, unless I quit the program
and restart it.
Could there be something else that might be capturing the other keys and
altering the functionality of the form? I had placed two buttons on the form
and noticed that the arrow keys were toggling the focus between the two
buttons, rather than scrolling the Panel.
Question:
How can I get the "scrolling" keys to fire the KeyDown event and prevent the
form from getting into that apparently form-editing state?
.
- Follow-Ups:
- Prev by Date: Re: Initialization order
- Next by Date: Re: Arrow Keys, PageUp, PageDn etc. Not Firing KeyDown Event
- Previous by thread: Shift scheduling algorithm
- Next by thread: Re: Arrow Keys, PageUp, PageDn etc. Not Firing KeyDown Event
- Index(es):