Hi, I have a GridCheckBoxColumn that im creating in codebehind with the DataField and Unique Name called active
I need to get its value in ItemDataBound so I can change the text of the Edit column based on this value. So this is what im doing
if (e.Item is GridDataItem)
{
GridDataItem dataItem = e.Item as GridDataItem;
if (dataItem["active"].Text == "False")
{
// Change edit column text here
}
else
{
// Change edit column text here
}
}
All my other columns in DataItem return the proper values but all the checkbox column returns is The visible and display are set to true and the CheckBoxColumn is visible. Is this the correct way to do this? ive tried searching the docs and forums for GridCheckBoxColumn but it either returns no results or I get a server error.
Thoughts?
-Keith
I need to get its value in ItemDataBound so I can change the text of the Edit column based on this value. So this is what im doing
if (e.Item is GridDataItem)
{
GridDataItem dataItem = e.Item as GridDataItem;
if (dataItem["active"].Text == "False")
{
// Change edit column text here
}
else
{
// Change edit column text here
}
}
All my other columns in DataItem return the proper values but all the checkbox column returns is The visible and display are set to true and the CheckBoxColumn is visible. Is this the correct way to do this? ive tried searching the docs and forums for GridCheckBoxColumn but it either returns no results or I get a server error.
Thoughts?
-Keith