Gridview write back table using c#

Gridview write back table using c#

GRGraybanGRGrayban Posts: 2Questions: 2Answers: 0

I would like to do something like this: https://editor.datatables.net/examples/extensions/excel.html
with data for my users. However, I pass the the DataTable C# Object to the gridview from a method. This is my normal table report. I would like to take it one step farther and edit the data and pertform an .update()l on the SqlDataAdapter and push everything back to the database.

Any guidelines you can give me?

Answers

  • allanallan Posts: 63,464Questions: 1Answers: 10,466 Site admin

    Hi Glen,

    Thanks for your message. We talked about this to some degree by e-mail - Editor's server-side libraries for .NET will work with an ADO.NET database connection, but it doesn't directly work with a System.Data.DataTable instance. Instead the Editor libraries will read the submitted data from the client-side, create the SQL needed in order to update the database and then execute that SQL. There isn't any need for an intermediate step.

    It would be possible to do what you are looking for, but not with the provided libraries. It would need a custom integration.

    Do you have an ADO.NET database connection (probably the one you are using for any existing SqlDataAdapter) that you can use?

    Regards,
    Allan

This discussion has been closed.