all groups > asp.net datagrid control > april 2008 >
You're in the

asp.net datagrid control

group:

Buttonfield columns ?



Buttonfield columns ? Savvoulidis Iordanis
4/24/2008 6:01:01 PM
asp.net datagrid control: I have a gridview based on a sqldatasource of 4 columns (c1,c2,c3,c4).
I only have 2 of them in the grid (c3,c4). I changed column c4 to be a
buttonfield so it is displayed as a link with the proper DataText coming
from the database. So far so good.

When this buttonfield column is clicked,
1. HOW can I get its datatext in the rowcommand event? (it differs on each
row). And also

2. HOW can I get the values of the other two columns (c1,c2) which
are not displayed in the gridview? These are the PK values which I need
to use along with the buttonfield text, but I don't want them displayed

AddThis Social Bookmark Button