Get RadGrid dataitem for binding

2 posts, 0 answers
  1. Kyler
    Kyler avatar
    5 posts
    Member since:
    Nov 2006

    Posted 08 Feb 2008 Link to this post

    I want to get the dataitem of the selected row in a RadGrid, then programmatically bind it to a FormView control.  I have tried...

    FormView1.DataSource = RadGrid1.SelectedItems(0)
    and
    FormView1.DataSource = RadGrid1.SelectedItems(0).Cells
    and
    FormView1.DataSource = RadGrid1.SelectedItems(0).OwnerTableView.Items

    But none of those expose the dataitems associated with the grid.  One other detail is that I want to bind dataitmes that might not necessarily be shown in the grid, but are included in the grid's datasource.

    THanks.
  2. Prangadj
    Prangadj avatar
    174 posts
    Member since:
    Jan 2008

    Posted 11 Feb 2008 Link to this post

    I found this demo which is quite helpful and is probably the most quick and easy solution:

    http://www.telerik.com/DEMOS/ASPNET/Prometheus/Grid/Examples/Programming/SelectedValue/DefaultCS.aspx

    Replace the second grid with FormView control and this should filter the data in the FormView when you select item.

    Prangadj
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top