Adding the Edit, Update, Cancel Button Column to the DataGrid

The first step in creating an editable DataGrid is to add the Edit, Update, Cancel Button Column, as follows:

1.
We first need to add a DataGrid to our ASP.NET Web page. To follow along, start by creating a new ASP.NET Web page named EditDataGrid.aspx and turn glyphs on.
2.
Then drag and drop a DataGrid from the Toolbox and onto the designer, within the Web form.
3.
Set this DataGrid's ID property to dgCustomers.
4.
Next open the DataGrid's Property Builder dialog box and navigate to the Columns screen.
5.
Since we will be specifying which columns should appear in the DataGrid, be sure to uncheck the “Create columns automatically at run time” checkbox.
6.
Under the “Available columns” ...

Get SAMS Teach Yourself ASP.NET in 24 Hours now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.