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

[Solved] ValueBinding on DataTimePicker

1 Answer 96 Views
DatePicker for XAML
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Florian
Top achievements
Rank 2
Florian asked on 22 Jan 2013, 01:18 PM
Hello Support,

i am using RadDatePicker in a PopUp, while binding a Nullable<DateTime> Property of my ViewModel to it.

This is what i have so far:
<telerikInput:RadDatePicker 
                        MaxHeight="180"
                        HorizontalAlignment="Stretch" 
                        x:Name="DateFrom"
                        ItemLength="100"
                  Value="{Binding CurrentDate}"
                        DisplayMode="Inline"  >
                        <telerikInput:RadDatePicker.SelectorHeaderTemplate>
                            <DataTemplate>
                                <TextBlock Text="Date from" Style="{StaticResource BaselineTextStyle}" Foreground="White" Margin="10,29,0,0" Padding="0,0,0,10"/>
                            </DataTemplate>
                        </telerikInput:RadDatePicker.SelectorHeaderTemplate>
                        <telerikInput:RadDatePicker.SelectorBackgroundStyle>
                            <Style TargetType="Border">
                                <Setter Property="BorderThickness" Value="0"/>
                            </Style>
                        </telerikInput:RadDatePicker.SelectorBackgroundStyle>
                    </telerikInput:RadDatePicker>

Now, if i set the "DisplayMode" to "Standart" the Value binding works.

On "inline" the control is only showing the current date, why won't it bind?

Thanks!

1 Answer, 1 is accepted

Sort by
0
Ivaylo Gergov
Telerik team
answered on 24 Jan 2013, 03:45 PM
Hi Florian,

Thank you for your interest.

I can confirm there is an issue with binding values when RadDatePicker is in Inline mode. I have logged this as bug and it will be fixed in our next official release. I have also updated your Telerik points for your valuable feedback.
For now, as a workaround I can suggest you to wait for Loaded event and set the value manually.

I hope this information is useful. Let me know if you need further assistance.

 

Regards,
Ivaylo Gergov
the Telerik team
Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
Tags
DatePicker for XAML
Asked by
Florian
Top achievements
Rank 2
Answers by
Ivaylo Gergov
Telerik team
Share this question
or