Insert Update Delete in ASP.NET Using GridView

Hi Developers, Here i am going to explain all important steps to perform insert update delete in using c# using GridView Control. This article i am going to use GridView Control to insert update delete records. Without Writing hard codes we can perform insert update delete. we should only proceed some wizards. Let see how to perform insert update delete in
1.Create New Project (Lenovo) –> Right click on Lenovo Project –>Add New WebForm(WebForm1) using C#.
Drag and Drop GridView into Designer Table. see below image.

2.Select and click –> Choose a Data Source Type –> SQL (Database). see below image.

3.Click “New Connection” , give all details of Data source.Test connection and click OK. see below image.

4.check the radio button of “Specify columns from a table or view”. choose the table. click “Advance”. check “Generate INSERT , UPDATE and DELETE statements. see below image. on Test Query and see all records of table. click FINISH.see below image.

6. Configure GridView , select a layout, select a style,Enable Editing,Inserting,Deleting,sorting and Paging press OK.see below image.

7.In Last steps,Project is ready , Run the Project and try insert update delete the records in the table.see below image.

Post Author: adama