This project is read-only.


Using storeapplib component 1.1.3 datepicker


I am using DatePicker in the project. I have embedded this control to select the date in the windows store app and user can also clear the displayed date using the "Clear" button.

Clicking on the "Clear" button setting the datePicker text to empty and setting the Date to currentDate.
But when Calender is opened to select new date, current date is already selected.
Trying to select the current date is not displaying in the control. Selecting other than current date is working properly.

Please provide any solution to the issue.

Closed Sep 21, 2013 at 8:12 AM by sureshkumart


sureshkumart wrote Sep 20, 2013 at 4:40 PM

Working on the fix

wrote Sep 21, 2013 at 8:12 AM

Resolved with changeset 30246: Added clear functionality to datecontrol

a171980 wrote Sep 26, 2013 at 12:04 PM

The issue is not fixed yet. When clicking on Clear button, setting the DatePicker text property with following below lines.

DatePickerControl.Text = "";

when again trying to select the current date is not displaying. Please let me know limitation of DatePicker controls.
As you have posted issue is fixed, I tested in the sample app but it seems issue is not fixed yet.


a171980 wrote Sep 26, 2013 at 2:57 PM

I got the latest version of DatePicker Controls. I used the Clear method to clear the date for the datePicker.
Now the date Picker is working fine.
We have done Binding with the DatePciker which is displayed first time when datePciker control is visible. When binded value is coming as null then DatePicker is allowing to select any Date.

Alok Pandey

a171980 wrote Sep 26, 2013 at 3:02 PM

In the previous post, I have written DatePicker is not allowing to select any date.

sureshkumart wrote Sep 27, 2013 at 8:15 AM

Do not use Text property of the date control. It is a read only property showing the formatted text. To work with date control, use Date property. This property data type is DateTime. To clear date, call the Clear() method, the Date property will be set to DateTime.MinValue and control value will be cleared. Otherwise you can set Date property to DateTime.MiniValue to clear the control, not null as null value cannot be assign to DateTime data type.

If you have still issue, share me the xaml declaration and line of code using date control.