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

Cancellation in DatePicker

3 Answers 53 Views
DatePicker and DateSelector
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Alex
Top achievements
Rank 1
Alex asked on 07 Aug 2012, 04:24 AM
Hello.

How can I check that user not choosed date and clicked cancel button in RadDatePicker? Maybe there is some sort of events?

Thanks.

3 Answers, 1 is accepted

Sort by
0
Accepted
Todor
Telerik team
answered on 07 Aug 2012, 07:17 AM
Hello Alex,

You can use the ValueChanged event. When the OK button in RadDatePicker is tapped the event is fired and when the Cancel button is tapped the event is not fired.

Kind regards,
Todor
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Alex
Top achievements
Rank 1
answered on 07 Aug 2012, 04:22 PM
Thanks. But I think that I can't use only ValueChanged event. I think that  to solve the problem it must be used in combination with PopupOpened and PopupClosed.
0
Accepted
Todor
Telerik team
answered on 08 Aug 2012, 07:13 AM
Hello Alex,

Yes, for your scenario the ValueChanged event won't suffice. You will need the PopupClosed event as well. You can have a flag isValueChanged set to false and change it when ValueChanged occurs. Then on PopupClosed you will know if the value has been changed or not and reset the flag.

Regards,
Todor
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
DatePicker and DateSelector
Asked by
Alex
Top achievements
Rank 1
Answers by
Todor
Telerik team
Alex
Top achievements
Rank 1
Share this question
or