Hi
I am using a GridDateTimeColumn and would like to be able to set the calander properties, namely the ShowRowHeaders property to false.
I have tried setting it in the ItemCreated & ItemDataBound events of the grid, but to no avail ... The code is below:
I can confirm that the above code is excuted, however the changes are not displayed. The radgrid is set to update itself in the radajax manager.
I am using a GridDateTimeColumn and would like to be able to set the calander properties, namely the ShowRowHeaders property to false.
I have tried setting it in the ItemCreated & ItemDataBound events of the grid, but to no avail ... The code is below:
| <telerik:RadGrid ID="MyRadGrid" runat="server" AllowPaging="True" AllowMultiRowSelection="true" | |
| AutoGenerateColumns="False" AllowAutomaticDeletes="True" AllowMultiRowEdit="true" | |
| AllowAutomaticInserts="False" AllowAutomaticUpdates="False" GridLines="None" | |
| AutoGenerateDeleteColumn="True" AutoGenerateEditColumn="false"> | |
| <ClientSettings Selecting-AllowRowSelect="true"> | |
| </ClientSettings> | |
| <MasterTableView DataKeyNames="MyId" EditMode="EditForms" CommandItemDisplay="Top"> | |
| <RowIndicatorColumn> | |
| <HeaderStyle Width="20px"></HeaderStyle> | |
| </RowIndicatorColumn> | |
| <ExpandCollapseColumn> | |
| <HeaderStyle Width="20px"></HeaderStyle> | |
| </ExpandCollapseColumn> | |
| <Columns> | |
| <telerik:GridDateTimeColumn DataField="date" HeaderText="date" UniqueName="date" | |
| PickerType="DateTimePicker" > | |
| </telerik:GridDateTimeColumn> | |
| </Columns> | |
| </MasterTableView> | |
| <FilterMenu EnableTheming="True"> | |
| <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation> | |
| </FilterMenu> | |
| </telerik:RadGrid> |
| void MyRadGrid_ItemCreated(object sender, GridItemEventArgs e) | |
| { | |
| if (e.Item is GridEditableItem && e.Item.IsInEditMode) | |
| { | |
| GridEditableItem item = e.Item as GridEditableItem; | |
| RadDateTimePicker date = item["date"].Controls[0] as RadDateTimePicker; | |
| if (date != null) | |
| date.Calendar.ShowRowHeaders = false; | |
| } |