1.

How Do We Update And Delete Data In A Gridview? Datakeynames Property In .net?

Answer»

The best way to Update or Delete a record in a GridView control is to INCLUDE a CheckBox column and a SUBMIT Button.

The GridView has its own Delete and Edit functionality. If the GridView is populated with data using an SqlDataSource, CHECKOUT the wizard that COMES along with the SqlDataSource. It may be used to automatically create an SQL Delete command and specify the delete parameters.

The DATAKEYNAMES property of the GridView is set to a field name of the Table.

The best way to Update or Delete a record in a GridView control is to include a CheckBox column and a Submit Button.

The GridView has its own Delete and Edit functionality. If the GridView is populated with data using an SqlDataSource, checkout the wizard that comes along with the SqlDataSource. It may be used to automatically create an SQL Delete command and specify the delete parameters.

The DataKeyNames property of the GridView is set to a field name of the Table.



Discussion

No Comment Found