This is a migrated thread and some comments may be shown as answers.

Scheduler KeyDown and KeyPressed Event Issue

1 Answer 110 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Sahand
Top achievements
Rank 1
Sahand asked on 23 Mar 2012, 07:35 PM
Hi,
Just reporting what I think might be a bug.
Using RadScheduler (2011 Q3) in any ViewType, the following events don't fire when pressing arrow keys:
  • KeyDown
  • KeyPressed
  • CellElementKeyDown
  • CellElementKeyPressed

Can you think of any workaround for this issue? I wanted to use it for solving this.

PS. I hope you don't mind me posting bugs all the time. I just like your product very much and this is the least I can do to help you improve them ^_^

1 Answer, 1 is accepted

Sort by
0
Accepted
Ivan Todorov
Telerik team
answered on 27 Mar 2012, 03:48 PM
Hello Sahand,

Thank you for writing.

This is rather not a bug, but the desired behavior of RadScheduler. The KeyDown and KeyPressed events are not fired because the navigation arrows are handled in a special way by RadScheduler. To achieve your scenario, you should override the ProcessCmdKey method of RadScheduler:
public class MyScheduler : RadScheduler
{
    protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
    {
        bool result = base.ProcessCmdKey(ref msg, keyData);
 
        if (keyData == Keys.Left)
        {
                 //do stuff here
        }
 
        return result;
    }
 
    public override string ThemeClassName
    {
        get
        {
            return typeof(RadScheduler).FullName;
        }
        set
        {
            base.ThemeClassName = value;
        }
    }
}

PS. Of course we do not mind receiving your feedback. Any feedback from our users is always welcome.

Regards,
Ivan Todorov
the Telerik team
RadControls for WinForms Q1'12 release is now live! Check out what's new or download a free trial >>
Tags
Scheduler and Reminder
Asked by
Sahand
Top achievements
Rank 1
Answers by
Ivan Todorov
Telerik team
Share this question
or