TabStrip captures arrow keys, ProcessCmdKey will not override that behavior

Thread is closed for posting
2 posts, 0 answers
  1. David
    David avatar
    2 posts
    Member since:
    Jul 2010

    Posted 14 Sep 2010 Link to this post

    I'm working with 2010 Q1, and I cannot override ProcessCmdKey to trap the left and right arrow key events.  It will work in a form without the tabstrip, but not in a form with a tabstrip.  Is this a known issue?

    My project is pretty far along using this version, and converting to the new version would basically require writing a new project and copying the code over.  The automatic upgrade stuff in 2010 Q2 SP1 is not appearing, probably due to the fact that my project uses Q1 dlls.  Replacing those dlls with Q2 versions causes a multitude of errors to appear.

    Any ideas?


  2. Stefan
    Stefan avatar
    2911 posts

    Posted 20 Sep 2010 Link to this post

    Hello David,

    Thank you for writing.

    You could try to override ProcessCmdKey as shown in the following code snippet:
    protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
            if (keyData == Keys.Left)
                base.ProcessCmdKey(ref msg, keyData);
                return false;
            return base.ProcessCmdKey(ref msg, keyData);
    This will prevent from stopping the event forwarding to radTabStrip1.KeyDown event and you will be able to catch in there, as shown in the next code snippet:
    void radTabStrip1_KeyDown(object sender, KeyEventArgs e)
        if (e.KeyData == Keys.Left)
    //Left arrow is pressed. Do something

    A bit off topic, please ask the person who has purchased our controls in your company to add you as a License Developer to the purchase. This will give you full access to the products your company has purchased, to our downloads section, and to our support ticketing system. Additionally, all your questions will be reviewed according to the license you have. More information on License Developers you can find here:

    All the best,
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top