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

RadCalendar arrow key navigation

2 Answers 91 Views
Calendar, DateTimePicker, TimePicker and Clock
This is a migrated thread and some comments may be shown as answers.
Lou
Top achievements
Rank 1
Lou asked on 09 Mar 2015, 04:01 PM
Hi, I would like to allow the user to change the currently selected RadCalendar day based on the arrow keys (as well as the mouse). How would I do that?
(It seems that using the arrow keys does not fire the RadCalendar.SelectionChanged event.)

Thanks,

-Lou

2 Answers, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 10 Mar 2015, 01:45 PM
Hi Lou,

Thank you for writing.

You can use the PropertyChanged event of the control to detect when the FocusedDate is getting changed (which will be changed when the arrow keys are pressed) and in it, set the control's SelectedDate:
void radCalendar1_PropertyChanged(object sender, PropertyChangedEventArgs e)
{
    if (e.PropertyName == "FocusedDate")
    {
        radCalendar1.SelectedDate = radCalendar1.FocusedDate;
 
    }
}

I hope that you find this information useful. Should you have any other questions, do not hesitate to contact us.

Regards,
Stefan
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Lou
Top achievements
Rank 1
answered on 10 Mar 2015, 02:52 PM
Thanks, that works !

-Lou
Tags
Calendar, DateTimePicker, TimePicker and Clock
Asked by
Lou
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Lou
Top achievements
Rank 1
Share this question
or