Hi,
I've been trying to find an example of hiding a value in a column in a RadGrid detail table. I've found examples on how to hide an entire column, but that's not what I'm looking for. I need the column to always be present, and want to hide the value in a row based on the value in that column.
As a simplified example, let's say I have a numerical column called "ID" in the detail table. If the value of the "ID" column is 0 then I want to hide that value for that row.
Here's how I achieved this for the master table in the PreRender event:
But I can not seem to figure out how to achieve the same thing in a detail table. Any assistance would be greatly appreciated.
Thanks!
I've been trying to find an example of hiding a value in a column in a RadGrid detail table. I've found examples on how to hide an entire column, but that's not what I'm looking for. I need the column to always be present, and want to hide the value in a row based on the value in that column.
As a simplified example, let's say I have a numerical column called "ID" in the detail table. If the value of the "ID" column is 0 then I want to hide that value for that row.
Here's how I achieved this for the master table in the PreRender event:
'Hide value of SelID if it's 0
For Each dataItem As GridDataItem In RadGrid1.Items
For Each col As GridColumn In RadGrid1.Columns
If col.UniqueName = "sel_id" Then
'getting the value of the BoundColumn
Dim value As String = dataItem("sel_id").Text
If value = "0" Then
dataItem("sel_id").Text = String.Empty
End If
End If
Next
Next
But I can not seem to figure out how to achieve the same thing in a detail table. Any assistance would be greatly appreciated.
Thanks!