This code you will write on update button click.
First off all bind primary key of database to datagrid column make it visible false and travel loop as
txtBookPrice= textbox from which you want to update txtBookId= test i.e. unique id coming from databaseCode:foreach(DataGridItem dataItem in DataGrid1.Items) { priceText = (TextBox)dataItem.FindControl ("txtBookPrice"); bookIdText = (TextBox)dataItem.FindControl("txtBookId"); Updatecode_for_perticular_row (); }
With help of unique id in for loop find particular text in textbox and update.



Reply With Quote

Bookmarks