This project has moved and is read-only. For the latest updates, please go here.

DateTimePicker possible issue?

May 10, 2012 at 11:06 PM

I am using the Date Time Picker, but I think I came across an issue.  

The control loads with the value from my object, but If I switch the date (using the calendar), the time portion of the control resets to "00:00".  I am not sure if this is something I am doing wrong or a defect.  I would expect it to maintain the time value that it currently has.

Any help would be greatly appreciated.


I created a control that derives off the DateTimePicker.  The reason for this is because I set the custom formats I want ("MM/dd/yyyy HH:mm").

	public class myDateTimePicker : DateTimePicker

Xaml I have:

 <myUI:myDateTimePicker x:Name="dpOutValue"
      IsEnabled="{Binding enabled}"
      Value="{Binding dateVal, Mode=TwoWay, ValidatesOnDataErrors=True, UpdateSourceTrigger=PropertyChanged, TargetNullValue={x:Static sys:String.Empty}}"
May 11, 2012 at 3:01 PM

Thank you to have signalled this issue.


I have created the following issue to solve the time portion of the control that is being reset to midnight.


As a side note, the DateTimePicker found in the latest version of the toolkit has all the properties necessary to support custom formats.  Here is the DateTimePicker I used to reproduce the problem:


<xctk:DateTimePicker Format="Custom"
                     FormatString="MM/dd/yyyy HH:mm"
                     TimeFormatString="HH:mm" />
May 14, 2012 at 7:33 PM

Thank you for the quick response!  Just curious when a fix might be available.

Aug 1, 2012 at 9:14 AM
Edited Aug 2, 2012 at 4:36 PM

Any news about this fixing? Some time estimates?


PS: For anyone interested, I've uploaded a patch that fixes this bug. You can download it from Source Code / Patches - patch no. 12662

Aug 7, 2012 at 2:47 PM

Thank you.

This bug will be fixed in the next version of the extended WPF Toolkit,