Rowupdating event of gridview

Posted by / 27-Apr-2020 12:31

We use the Row Updating event of Grid View to update the record in the database table.We get the Id value using the row index and another Text Box value is also retrieved.

The Edit Index property of a Grid View determines the index of a row in edit mode. Update record and get updated state of the Grid View.Now we access this connection string on the page so we can open a connection with the relation database. The first one accesses the connection string and the other is for the SQL connection.Now we define a method for opening a connection with the relation database and returns a SQL connection object depending on the connection string that is passed as a parameter of the Sql Connection class constructor.All updated values are passed to the Stored Procedure.For a while now I’m trying to figure out why my method, triggered by the Grid View.

rowupdating event of gridview-73rowupdating event of gridview-47rowupdating event of gridview-64

In my VB Gridview, I had bind several column from datatable into one single column of the gridview. The following is the VB code: Protected Sub Grid View1_Row Editing(By Val sender As Object, By Val e As Grid View Edit Event Args) 'Set the edit index. Bind Data() End Sub Protected Sub Grid View1_Row Canceling Edit(By Val sender As Object, By Val e As Grid View Cancel Edit Event Args) 'Reset the edit index. Edit Index = -1 'Bind data to the Grid View control.

One thought on “rowupdating event of gridview”