none
Inserting data from datagridview to sql server 2000 database RRS feed

  • Question

  • Sir,

          How can I insert data from datagridview to database sql server 2000, when we add a particular row or edit a particular cell of the datagridview?

    Tuesday, July 10, 2007 7:42 AM

All replies

  • Moved this thread to the .NET Framework Data Access and Storage forum.
    Tuesday, July 10, 2007 3:42 PM
  • Hi,

     

    Add - You can create a procedure to add a record into you database and then retreive the new records and bind it again to your datagrid.

     

    Update - create a SQLdatasource object link to your data and enable "Update" button in your gridview. create a code in the  "Row Updating" event to save the changes.

     

    I hope this helps.

     

    Goodluck,

     

    Wilmar Acosta

    Tuesday, July 10, 2007 4:38 PM
  • pls. give me a sample code.
    Thursday, July 12, 2007 11:19 AM