how to insert update delete auto use RadGridView?

3 posts, 1 answers
  1. tuonglam
    tuonglam avatar
    3 posts
    Member since:
    Sep 2011

    Posted 01 Sep 2011 Link to this post

    GridView WPF control can insert update delete automatic and insert connection to SQL.How can i do like that in RadGridView?if can,can you make a video to easy understand?I want to insert update delete like the demo Command of RadGridView 100% with SQL server using C#.how con i do?

    thank you  thank you very very much!Please!
  2. Answer
    Martin Gartmann
    Martin Gartmann avatar
    51 posts
    Member since:
    Apr 2004

    Posted 01 Sep 2011 Link to this post

    Hi tounglan,

    what you should do is to subscribe to the RowsChanged Event of your Grid.

    Lets asume you have a Dataset named KundenDS and a TableAdapter named 
    KundenTableAdapter then your code block could looks like this

    Private Sub rgvKunden_RowsChanged(ByVal sender As Object, ByVal e As Telerik.WinControls.UI.GridViewCollectionChangedEventArgs) Handles rgvKunden.RowsChanged
         KundenTableAdapter.Update(KundenDS)
    End Sub

    Sorry that i provide the code in VB.Net. Use Telerik Code converter for your needs.

    See this link for more detailed information

    http://msdn.microsoft.com/en-us/library/ms233819(v=vs.80).aspx


    Kind Regards

    Martin Gartmann
  3. UI for WinForms is Visual Studio 2017 Ready
  4. tuonglam
    tuonglam avatar
    3 posts
    Member since:
    Sep 2011

    Posted 01 Sep 2011 Link to this post

    I want to say thank you very much to Martin Gartmann!

    Your post is very good but I expect use RadGridView control auto connect and command insert update delete like RadGridView command demo.Thank you very much!
Back to Top