Hi Developers, Here i am going to explain all important steps to perform insert update delete in asp.net using c#.
This article i am going to use List View 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 asp.net.
1.Create New Project (Sony) –> Right click on Sony Project –>Add New WebForm(InsertUpdateDel) using C#.
Drag and Drop List-view into Designer box. 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.
5.click on Test Query and see all records of table. click FINISH.see below image.
6.Configure ListView , select a layout, select a style,Enable Editing,Inserting,Deleting 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.