Hi,
I have a rad grid in which I have a column which is a template column and this column is always in edit mode.
The template column has a rad Date Picker. I want to set the rad date picker date in the RowCreated Client side event of the rad grid.
I have tried with this but its unable to do so,
Please help me out. I need to do it in the RowCreated event handler on client side.
I have a rad grid in which I have a column which is a template column and this column is always in edit mode.
The template column has a rad Date Picker. I want to set the rad date picker date in the RowCreated Client side event of the rad grid.
<
telerik:GridTemplateColumn
UniqueName
=
"CustomerStartDate"
HeaderText
=
"Customer Start Date"
DataField
=
"CustomerStartDate"
HeaderStyle-Width
=
"80px"
SortExpression
=
"CustomerStartDate"
>
<
ItemTemplate
>
<
telerik:RadDatePicker
ID
=
"radDatePickerCustomerStartDate"
runat
=
"server"
DbSelectedDate='<%# Bind("CustomerStartDate") %>'
ShowPopupOnFocus="true" DateInput-DateFormat="MM/dd/yyyy">
<
ClientEvents
OnDateSelected
=
"radDatePickerCustomerStartDate_OnDateSelected"
></
ClientEvents
>
</
telerik:RadDatePicker
>
</
ItemTemplate
>
</
telerik:GridTemplateColumn
>
I have tried with this but its unable to do so,
var date =
new
Date();
args.get_gridDataItem().findControl(
'radDatePickerCustomerStartDate'
).get_element().set_selectedDate(date);
Please help me out. I need to do it in the RowCreated event handler on client side.