Hi,
In the ItemDataBound event of my datagrid, I want to change the text on the select ButtonColumn for some rows, depending on the value of some of the cells in that row. The text I want to put on the ButtonColumn is not always the same and also depends on those same values; basically it will say how many items are left if there are less than 10.
When I change the text on the ButtonColumn select cell, the selecting-property of that cell disappears. So, where an unchanged ButtonColumn cell would be a sort of 'hyperlink' that selects that particular row, the changed text will just be text and clicking it does not fire any events...
A workaround is to create an additional column in the table I use as a datasource and set the Textfield property of the select ButtonColumn to that column, but I was just wondering why the selecting-property would disappear. I use this to change the text property:
e.Item.Cells[0].Text = "## items left";
Ok, long story for a short question, but I am curious and have found nothing on google that addresses this situation. Any ideas here as to why the ButtonColumn seems to cease being a ButtonColumn??
cheers,
hokje
In the ItemDataBound event of my datagrid, I want to change the text on the select ButtonColumn for some rows, depending on the value of some of the cells in that row. The text I want to put on the ButtonColumn is not always the same and also depends on those same values; basically it will say how many items are left if there are less than 10.
When I change the text on the ButtonColumn select cell, the selecting-property of that cell disappears. So, where an unchanged ButtonColumn cell would be a sort of 'hyperlink' that selects that particular row, the changed text will just be text and clicking it does not fire any events...
A workaround is to create an additional column in the table I use as a datasource and set the Textfield property of the select ButtonColumn to that column, but I was just wondering why the selecting-property would disappear. I use this to change the text property:
e.Item.Cells[0].Text = "## items left";
Ok, long story for a short question, but I am curious and have found nothing on google that addresses this situation. Any ideas here as to why the ButtonColumn seems to cease being a ButtonColumn??
cheers,
hokje