This is a migrated thread and some comments may be shown as answers.
Timepiker
1 Answer 17 Views
This is a migrated thread and some comments may be shown as answers.
ahmed
Top achievements
Rank 1
ahmed asked on 17 Jun 2010, 02:06 AM
Unable to cast object of type 'System.DBNull' to type 'Telerik.Web.UI.RadTimeView'.

i got that error

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 1
answered on 17 Jun 2010, 11:53 AM
Hello Ahmed,

I guess you are using RadTimePicker inside any DataBound control and getting error when fetching a null value. If so, you need to use DbSelectedDate instead of SelectedDate when binding the RadTimePicker.


Here is an example:
 
    <telerik:GridTemplateColumn> 
        <ItemTemplate> 
            <telerik:RadTimePicker DbSelectedDate='<%#Eval("StartTime") %>' ID="RadTimePicker1" runat="server"
            </telerik:RadTimePicker> 
        </ItemTemplate> 


-Shinu.
Asked by
ahmed
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 1
Share this question
or