The effect before and after adding is as follows
1 Before adding
2. After adding
The specific steps are as follows:
1. Right-click the control, select "Edit Column", select Add Column, select DataGridViewLinkColumn, edit the name and text, and click OK
2. Add two link columns for deletion and modification
3. Modify the NullValue data in DefaultCellStyle for you to add The name of the link column
4. Add a column of check box type,
5. Click the move button to move the check box to the first position
5. This is the final interface
This part is to organize the data deletion function that interacts with the database in the DataGridView
Behind the project needs, you need to add a column in the student table of the database. The default value of int is set to 0.
This column is automatically generated in the database table.
Register the DataGridView event: CellContentClick, click the content in the cell to trigger the event