Gridview rowupdating in asp net using c
Text; bit when ichange it to string id =((Text Box) Grid View1.
Contol)Text; it werk just Fine any comment and thx for the code Instead of adding a Customer ID to your table and later pulling the text to get the ID number, a more reliable way to do it is to add a Data Key Names field to the grid example in the page: You can then access this information at any time with the following in code: Grid View1.
These properties will automatically render Edit, Update and Cancel buttons inside Grid View column.
I am using Template Field’s Item Template and Edit Item Template for providing read only and editing interface of the same column in the Grid View.
To do this we first need to obtain the reference of the current row by using its index no as shown in the first line below.
By using the Grid View Row object we can find the reference of any control in the row in which user is editing the data.
Search for gridview rowupdating in asp net using c:
Data Keys[Row Index]["Customer ID"]in the Update event it would be something like:int Customer ID = Convert.