| Available dates | |
|
3/10/2006 12:00:00 AM
| Edit |
|
3/15/2006 12:00:00 AM
| Edit |
|
| Edit |
|
| Edit |
|
4/1/2006 12:00:00 AM
| Edit |
Source Code & Description
Binding a RadDatePicker to a data source is easy provided you use the DbSelectedDate property. It works almost like the SelectedDate one, but will not throw an exception when it has been given a null value.
This example demonstrates binding a DataGrid control to a DataTable with dates, containing null values. Binding the date is done via the DbSelectedDateProperty:
<EditItemTemplate>
<rad:RadDatePicker id="Raddatepicker2" MinDate="2006/1/1" AllowEmpty="True" Runat="server" DbSelectedDate='<%# DataBinder.Eval(Container.DataItem, "Dates") %>'>
</rad:RadDatePicker>
</EditItemTemplate>