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

Is there a simple way to check if changes in the input fields have been commited?

3 Answers 46 Views
DateTimePicker
This is a migrated thread and some comments may be shown as answers.
ClausDC
Top achievements
Rank 1
Iron
ClausDC asked on 02 Aug 2013, 01:19 PM
While the user types into the input field, changes are only "commited" (to the SelectedValue property) when the control loses focus or when the user hits "Enter".

Is there a simple way to check if the control's status is currently "committed" or "not-committed" (i. e. the user has typed something into the box but hasn't hit Enter or activated another control) without to resorting to value comparisons (which would mean to parse Date values etc. which I want to avoid)?

3 Answers, 1 is accepted

Sort by
0
Kalin
Telerik team
answered on 06 Aug 2013, 01:53 PM
Hello Claus,

I would suggest that you use the CurrentDateTimeText property of the DateTimePicker  - it contains the entered text in the input field of the control and is updated with every keystroke. This way you can get the changed text at any moment before it gets parsed when focus lost or Enter pressed.

Hope this helps.

Regards,
Kalin
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
ClausDC
Top achievements
Rank 1
Iron
answered on 07 Aug 2013, 08:34 AM
Thanks, I knew about this field but I had hoped that there is some kind of status property which would let me avoid string comparisons.

0
Kalin
Telerik team
answered on 07 Aug 2013, 11:16 AM
Hello Claus,

Unfortunately this is the only property that can be used as per the requirement.

If you have any other questions, let us know.

Regards,
Kalin
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
DateTimePicker
Asked by
ClausDC
Top achievements
Rank 1
Iron
Answers by
Kalin
Telerik team
ClausDC
Top achievements
Rank 1
Iron
Share this question
or