473,396 Members | 1,861 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,396 software developers and data experts.

form keypreview, comboxes & datagrid

hi,

i need to preview the keys in my app in order to process F1-F10. i set
keypreview of my form to true, and it does capture the keystrokes from all
over the forms controls which i then
process.

i found 2 puzzeling exception: if the user is inside the text box of a
ComboBox, the keystrokes aren't
captured in the form's keypress event. i have to separately capture the
keypress event of the combobox.

it is even worse in the datagrid. if the user is inside a cell, the form's
keypress is not captured. if u click on on row or column caption then the
form's keypress event works, but not if the u r inside the cell. i couldn't
find a solution for this, because if i capture the datagrid's keypress, it
too only works if the focus is not inside a cell. this is very weird. how do
i capture form keypresses or even datagrid keypresses when a user is inside
a cell within a datagrid?

thanks for any help

ray


Nov 16 '05 #1
1 3209

I have also been working on keyboard navigation for datagrid with
extended columnstyles (combobox included). In my case I want to capture
ENTER as a toggle to combobox.droppeddown and then use UP/DOWN arrow
keys to navigate the combo list. I am part of the way there.

You might find some help here:

http://www.i-syn.gmxhome.de/devcom/c...es/textbox.htm
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #2

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

Similar topics

3
by: babu | last post by:
Hello All, How are you? I am facing an issue to print all the form control values (including datagrid values). Is there a way to print all the control values in VB.NET. If the grid...
5
by: Steve M | last post by:
I have subclassed CollectionBase. I have also implemented GetEnumerator(). I have tried to set the DataSource of a DataGrid to an instance of my subclass. However, the items in the grid are not...
0
by: Chuck | last post by:
I have KeyPreview set to true for my form. How do I ucase all of my keyboard input at this level?
2
by: Carl Tribble | last post by:
I am using KeyPreview on the form to trap Function-keys. My form includes a datagrid. I am using the Form.KeyDown event to trap the keys and all works fine unless the datagrid is showing one or...
1
by: Rene | last post by:
Hi, I am running is some problems with the KeyPreview and KeyPress events. The KeyPress event is only triggered when there this an focusable control on the form. When all controls are disabled...
0
by: RB | last post by:
Hi, I have retreived questions and answers from DB tables, and display them into datagrid. QNo Quest A B C 1 Quest1 5 7 9 2 Quest2 A D C 3 Quest3 gold silver bronze The values for possible...
6
by: Erik H. | last post by:
Trying to connect to MySQL db on localhost, and populate datagrid from a dataset using code inline method. Getting the following compile error: Error Message: "CS0246: The type or namespace...
13
by: HABJAN ®iga | last post by:
I'am using form's keypreview property & keydown (on form) to look for hotkeys (alt+?) Everything works fine, except when i have focus on combobox. Then the event on form isn't raised. Can...
1
by: sg | last post by:
Hi I'm starting programming in visual studio and c# and i have a problem with filtering datagrid. I build form with datagrid and i see data from database. I find in microsoft web page...
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:
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...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.