Get Selected Rows, display in second grid in session

2 posts, 0 answers
  1. Brett
    Brett avatar
    184 posts
    Member since:
    Jun 2006

    Posted 11 Apr 2008 Link to this post

    My grid has a check box column, once I select all my items I click a button.

    On the button click I want to "copy" only the selected rows into a second grid.  I do not want to commit anything to a database yet as the second grid acts as a summary, so they may go back and select more rows in the first grid.

    Can someone help me on my way here?

  2. Maria Ilieva
    Maria Ilieva avatar
    4017 posts

    Posted 14 Apr 2008 Link to this post


    In order to scheived the required functionality, you can attach to the OnRowSelected event handler, and iterate through the RadGridClientObject.MasterTableView.SelectedRows collection.
    This will give you access to all the rows currently selected, and you can then access each cell individually, to get its value.
    After that you could initiate an ajax request to add the selected values in the second RadGrid DataSource (if the both DataSources has the same structure).
    I hope this is a suitable approach for you.

    Maria Ilieva
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top