473,464 Members | 1,716 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Force Ctrl+F1 to behave like Ctrl+Tab

MDI WinForms 2 application.
I need that Ctrl+F1 cycles through windows like Ctrl+Tab and Ctrl+Tab is
redefined.
I overrided MDI child form OnKeypress method but Ctrl+F1 press is ignored.
For unknown reason base.ProcessCmdKey calls method itself.

How to fix ?

Andrus.

protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
{
switch (keyData)
{
case Keys.Control | Keys.Tab:
// ... custom processing occurs hear.
return true;

case Keys.Control | Keys.F1:
keyData = Keys.Control | Keys.Tab ;
break;
}
return base.ProcessCmdKey(ref msg, keyData);
}

Jun 27 '08 #1
0 1300

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

Similar topics

0
by: Kaki | last post by:
I have a RichTextBox with AcceptsTab set to true. When Ctrl is held down, pressing Tab does not trigger KeyPress or KeyDown/Up events. If AcceptsTab is false, the RichTextBox never knows if Tab...
3
by: Glen Hong | last post by:
I have set up a hotkey using RegisterHotKey API function for Ctrl-Tab. Firstly, I can rap this when Ctrl-Tab is pressed however if I want to add an addition hotkey how can I distinguish between...
4
by: Oenone | last post by:
I'm using a TabControl to facilitate a wizard-style form, using some of the techniques described here: http://www.codeproject.com/cs/miscctrl/WizardTab.asp For the most part I have this...
4
by: Nathan M | last post by:
Hi, I'm having trouble disenabling the use of Ctrl+Tab to switch tabs in a tab control. I've tried adding the following code in an event handler that handles the KeyDown event for the form, the...
17
by: Kbalz | last post by:
I'm developing a Wizard type program, and I'm flipping between steps by using a TabControl.. buttons on each tabPage move to the next or previous tabPage. When I press CTRL+Tab however, the...
0
by: Frode | last post by:
When I press Ctrl+Tab in VS2005, the popup-window showing my child windows/tabbed windows won't auto-close when I release the control key. The popup-window stays open until I press enter. Anyone...
3
by: raja11112222 | last post by:
Hi i used five pages in property sheet. when i click CTRL + Tab it goes to next pages, I want to stop this Scenario ie if i click CTRL + Tab, it wont goes to next page. How can i stop this...
10
by: thupham | last post by:
Dear all friend, I want disable Ctl+Alt+Del; Ctrl+Esc; Ctrl+tab, Alt+Tab, Start button, ctrl+Alt+Del, lock all keys on the keyboard. Have you ever do it in C#. Help me. Thanks for all reply.
1
by: John B. | last post by:
Please forgive my rant, but trapping keystrokes in .NET couldn't get much worse if someone tried. Sorry to vent my frustration but I've had no end of problems with this for the past 18 months. The...
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,...
1
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
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,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.