473,394 Members | 1,806 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Scrollbars catching KeyUp event...

I've got a control inheriting from UserControl, with a scrollbar docked to
the right. I'm using KeyUp on my control to capture cursor keys and move
things about the control accordingly (I've override the OnPaint method on my
control, and use that to draw). This works great, but the cursor keys *also*
scroll the scrollbar. Is there any way I can stop this? When the items I'm
moving about my control hit the bottom, I'll increase the Value of the
scrollbar myself, but I just don't want it capturing cursor keys from it's
container (my control).

I've tried setting .Handled to true in the event handler, but (probably
because event handlers are called after the base methods?) it doesn't stop
:-(

--
Daisy The Cow
Now playing: Jamiroquai - Little L
Nov 13 '05 #1
0 1482

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Ori | last post by:
Hi Guys, Here is my problem, but maybe someone can help me with this. Background: 1. Using C#. 2. I'm having a form which the KeyPreview is on (and must stay like this) and I'm...
2
by: Adam J. Schaff | last post by:
I have recently noticed an unwanted behavior that I do not know how to get rid of. To Recreate Problem: Windows Forms App with 2 forms. Form 1 has nothing on it and this code underneath: ...
4
by: ShaneO | last post by:
I would like to handle the KeyUp & KeyDown events in the same event handler but can't find how to determine which event was fired - Private Sub ListBox1_KeyUp(ByVal sender As Object, ByVal e As...
0
by: WhiteWizard | last post by:
I have a windows app that requires I use the Microsoft Datagrid. My users would like to be able to select multiple rows using the Shift and Ctrl keys, and the datagrid has the selection...
1
by: Frank O'Hara | last post by:
I think I'm losing my mind, granted it is kind of late here so... I'm trying to do some simple validation on the client as keys are pressed. The validation routine works well enough however I...
11
by: Ben | last post by:
Hello, I'm trying to catch the pressing of the left and right arrow keys through the KeyUp event, like so: public Form1() { InitializeComponent(); Form1.ActiveForm.KeyUp += new...
1
by: jayturley | last post by:
I have a web page with the following items on it: <label for="commissionschedule"> Commission Schedule<br /> <span id="charCounter">1000 characters or less</span> </label> <textarea...
1
by: Chris Jobson | last post by:
>I have a canvas which I use for dragging shapes around such as rectangles Add Focusable="True" to the XAML for the PolyLine and Rectangle elements and then when you set the focus to them they...
2
by: Tony Johansson | last post by:
Hello! I have created a Control that consist of a label and a textbox.I have called this class ctlLabelTextbox. public partial class ctlLabelTextbox : UserControl { .... } The class that I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.