Hello,
I am manipulating a cell's text by using the Grid_ItemDatabound event. See below:
This works fine until I place the grid in Edit Mode. When I do, the text in the cell defaults back to the value coming from the datasource (1000, 1002, or 1003). The value in this particular cell is ReadOnly, so I am not allowing edit. How can I get the cell text to stay the way I format it regardless of what mode the grid is in? I've tried several combinations of things using the IsInEditMode, GridEditableItem, GridEditFormItem, etc.
Thank you for any help you can offer.
Frustrated,
Jim
I am manipulating a cell's text by using the Grid_ItemDatabound event. See below:
If TypeOf e.Item Is GridDataItem Then Dim gridDataItem As GridDataItem = e.Item Dim quoteID = gridDataItem.Item("quoteID").Text Dim lineID = gridDataItem.Item("lineID").Text Select Case gridDataItem.Item("assortmentTypeID").Text Case 1000 gridDataItem.Item("assortmentTypeID").Text = "Text for 1000" Case 1002 gridDataItem.Item("assortmentTypeID").Text = "Text for 1002" Case 1003 gridDataItem.Item("assortmentTypeID").Text = "Text for 1003" End Select End IfThis works fine until I place the grid in Edit Mode. When I do, the text in the cell defaults back to the value coming from the datasource (1000, 1002, or 1003). The value in this particular cell is ReadOnly, so I am not allowing edit. How can I get the cell text to stay the way I format it regardless of what mode the grid is in? I've tried several combinations of things using the IsInEditMode, GridEditableItem, GridEditFormItem, etc.
Thank you for any help you can offer.
Frustrated,
Jim