Adding a RadGrid in a RadTreeViewItem

6 posts, 0 answers
  1. prakash
    prakash avatar
    7 posts
    Member since:
    Oct 2010

    Posted 05 Jan 2012 Link to this post

    Hi Everyone,

    I need to show a radgrid inside a radtreeviewitem. could you please direct me in achieving this task. I don't want to use RadTreeListView,  using RadTreeView I need to do that.

    Thanks in advances
    Prakash.
  2. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 10 Jan 2012 Link to this post

    Hello prakash ,

     I prepared a solution for you which demonstrates how you can use a RadGridView inside a RadTreeViewItem's Header. Please let us know if this could fit in your scenario or not.

    Greetings,
    Petar Mladenov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. DevCraft banner
  4. prakash
    prakash avatar
    7 posts
    Member since:
    Oct 2010

    Posted 13 Jan 2012 Link to this post

    Hi Petar Mladenov,

    Thanks for your response unfortunately It doesn't solve my requirement.
    My Requirement: Tree view shows list of employees and on selecting each employee node I need to show the employee details in a grid. For example purpose I've specified using Employee details. Could you please provide the solution at the earliest.

    Thanks,
    Prakash.
  5. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 16 Jan 2012 Link to this post

    Hi prakash ,

    You can place the GridView as a RadTreeViewItem which is child of the selected item like so:
    <telerik:RadTreeView x:Name="tree"  Background="AliceBlue" IsExpandOnSingleClickEnabled="True">
              <telerik:RadTreeViewItem Header="Employee A">
                      <Grid>
                          <Grid.ColumnDefinitions>
                              <ColumnDefinition />
                              <ColumnDefinition />
                          </Grid.ColumnDefinitions>
                          <TextBlock Text=" Grid Alpha " FontWeight="Bold" FontSize="14" VerticalAlignment="Center" />
                          <telerik:RadGridView Grid.Column="1" x:Name="gridView" Height="120" HorizontalAlignment="Stretch" Width="500" />
                      </Grid>
                  </telerik:RadTreeViewItem>
          </telerik:RadTreeView>
    Please give it a try and let us know if this satisfies you.
     
    All the best,
    Petar Mladenov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  6. Sri
    Sri avatar
    1 posts
    Member since:
    Dec 2012

    Posted 17 Dec 2012 Link to this post

    Hi,

    I added radgridview inside treeview as mentioned below. But the radgrid view is adding additional column at the end.
    Could you please suggest.

    Thank,
    Sri
  7. Tina Stancheva
    Admin
    Tina Stancheva avatar
    3298 posts

    Posted 20 Dec 2012 Link to this post

    Hello Sri,

    Please take a look at this article and let us know if you have more questions.

    Regards,
    Tina Stancheva
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top
DevCraft banner