Re: scrollbar bound to arrow keys



I found the solution. I didn't realize the Keydown is not fired for control keys. The function you need to override is ProcessDialogKey. Returning true from this function signifies that the key has been processed and no further processing is performed.


Morten Wennevik [C# MVP] wrote:
Hi,

Scrollbars do not automatically grab the arrow key events unless there is nothing else taking key input. Firing up a simple program with a HScrollBar and a button to switch visibility on the scrollbar I could not reproduce your problem. Once the scrollbar was invisible, it did not adjust the position when using the arrow keys.

Do you have custom binding or key handling that could interfere?

.