hierarchical grid

7 posts, 0 answers
  1. mww
    mww avatar
    257 posts
    Member since:
    Sep 2012

    Posted 03 Feb 2009 Link to this post

    can anyone show me where I can find some examples of hierarchical data in a grid ?
    I have 2 tables (master and detail).  I need the examples in c#
  2. Daniel
    Admin
    Daniel avatar
    4943 posts

    Posted 03 Feb 2009 Link to this post

    Hello Mark,

    Please examine the following resources:

    Documentation:
    What you should know
    Understanding hierarchical grid structure
    Creating hierarchical grids from design-time

    Demos:
    Three-level hierarchy
    Several tables at a level
    Hierarchy with declarative relations
    Hierarchy with DetailTableDataBind event

    Let us know if you need more information.

    Best regards,
    Daniel
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. mww
    mww avatar
    257 posts
    Member since:
    Sep 2012

    Posted 03 Feb 2009 Link to this post

    Ive looked at the examples and modified it to suit my needs.  I only have one details table, the contents of this table are determined by the contents of 2 columns in the master table (neither of which is the datakey)  How can I obtain these values in the 

     

    DetailTableDataBind event ?

  5. Daniel
    Admin
    Daniel avatar
    4943 posts

    Posted 03 Feb 2009 Link to this post

    Hello Mark,

    For your convenience I attached a simple examine to this post.

    I hope this helps.

    Best regards,
    Daniel
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  6. mww
    mww avatar
    257 posts
    Member since:
    Sep 2012

    Posted 03 Feb 2009 Link to this post

    How do I work with insert, delete and updates  for the master and detail tables ?
  7. mww
    mww avatar
    257 posts
    Member since:
    Sep 2012

    Posted 03 Feb 2009 Link to this post

    I dont want all the values in the parent control.  Isnt there some way of getting the value of a specific column in the parent grid ?

    for instance, the master table has 3 columns

    ID , ArtistID &  Genre

    I only need the values contained in the genre  and ArtistID columns to determine the contents of the detail table
  8. Daniel
    Admin
    Daniel avatar
    4943 posts

    Posted 06 Feb 2009 Link to this post

    Hello Mark,

    Alternative approach is to access the cell contents directly.
    protected void RadGrid1_DetailTableDataBind(object source, GridDetailTableDataBindEventArgs e) 
        if(yourCondition) 
        { 
            GridDataItem dataItem = (GridDataItem)e.DetailTableView.ParentItem; 
            string artistID = dataItem["ArtistID"].Text; 
        }  

    Let us know whether this helps.

    Regards,
    Daniel
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017