Hi,
I have a grid with a column as,
<rad:GridBoundColumn DataField="ProcessDescription" EditFormColumnIndex="1" HeaderText="Description" UniqueName="Description">
<HeaderStyle Font-Bold="true" />
</rad:GridBoundColumn>
Now when i tried to make certain columns as disabled in edit mode in the ItemDatabound event, its working fine but when i move the cursor on top of that disabled field, i get a javascript error which says
My aim is to just display it in a label with the text in grid.
I tried disabling as below,
if (e.Item is GridEditableItem && ((GridEditableItem)e.Item).IsInEditMode)
{
GridEditableItem editItem = (GridEditableItem)e.Item;
TextBox txtDesc = (TextBox)editItem["Description"].Controls[0];
txtDesc.Enabled = false;
}
Similar to this i have a date column as
<rad:GridDateTimeColumn DataField="EndDate" EditFormColumnIndex="0" DataFormatString="{0:d}" meta:resourcekey="GridTemplateColumnResource2">
<HeaderStyle Font-Bold="true" />
</rad:GridDateTimeColumn>
When i edit mode, i need to display only the date in a label and not in a date control. I want to make it not to be visible when in insert mode.
"Sys.ArgumentException: Value must be a DOm element. Parameter name:element".
How to solve this or Is there a better method to make certain columns in a grid as disabled when in editmode.
In Insert mode ( i mean when i click ' Add new record' link at the top of the grid), i want to make this column as not visible. How will i be able to achieve this?
Regards
Sujith