Completed
Last Updated: 13 May 2020 13:13 by ADMIN
Release R2 2020
n/a
Created on: 03 Mar 2020 17:03
Category: DateTimePicker
Type: Bug Report
1
DateTimePicker: The first visible date cannot be selected if DefaultDate is set

Hi, I checking DateTimePicker control, and I'm not sure if it's bug of feature.

I have picker control bound to nullable DateTime property.
DefaultDisplayDate is bound to DateTime.Now, for help select date in spinner when selectedDate is null.

But in such situation select today date from spinner not change anything, I suppose that date change event not fire.

01.<telerikInput:RadDateTimePicker Grid.Row="7" Grid.Column="1"
02.              x:Name="dtxProdDate"
03.              PlaceholderLabelStyle="{StaticResource PlaceholderLabelStyle}"
04.              DisplayLabelStyle="{StaticResource DisplayLabelStyle}"
05.              TabStripItemStyle="{StaticResource TabStripItemStyle}"
06.              SelectedDate="{Binding TestObj.NullableProdDate}"
07.              DisplayStringFormat="yyyy-MM-dd"
08.              SpinnerFormatString="yyyy-MM-dd"
09.              DefaultDisplayDate="{Binding TodayDate}"
10.              Placeholder="Select date..." />
1 comment
ADMIN
Didi
Posted on: 04 Mar 2020 12:12

Hi Maciej,

Than you for the provided code.

I have tested the scenario and I reproduced the issue on my side. It seems that when popup is open the first visible date cannot be selected when click OK button and the DefaultDisplayDate is set.

I have converted this forum thread into a public bug report. Find your Telerik points updated as a small sign of gratitude for your involvement.

Workaround:

Implement AcceptCommand (which is executed when Popup OK button is clicked) and inside it you can set different value for the SelectedDate property. I have attached a sample. Download it and give it a try.

Regards,
Didi
Progress Telerik

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Attached Files: