Change RadTreeNode's width to window's width and clickable

5 posts, 0 answers
  1. Dev
    Dev avatar
    28 posts
    Member since:
    Jan 2011

    Posted 13 Jul 2013 Link to this post

    Hello,

    I am using telerik version 2012.1.515.35 with ASP.NET 3.5, C# 2008.

    I have a RadTreeview on ASPX page in side a DIV.

    The requirement is make RadTreeNode's width 100% of DIV width and also the node should be click-able (can be able to fire client side events).

    I tried to set the width of node in NodeDataBound event but the result is nothing.

    I also have tried to set width of class .rtIn to 100% but it is not changing the result.

    Please see my attached screen-shot.

    Any solution?

    Thanks
  2. Magdalena
    Admin
    Magdalena avatar
    421 posts

    Posted 17 Jul 2013 Link to this post

    Hi Devendra,

     The element with a css class .rtIn is an inline element so to set the custom width, it is necessary to make it an inline-block element. Please, try to apply a following stylesheet to your project

    html .RadTreeView_Default .rtIn {
        width: 97%
    }
    Regards,
    Magdalena
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Dev
    Dev avatar
    28 posts
    Member since:
    Jan 2011

    Posted 19 Jul 2013 Link to this post


    Hello Magdalena,

    I tried using

    html .RadTreeView_Default .rtIn {
        width: 97%;
    }

    But it is still not working.

    Can you provide me any sample project? Or any other working solution for the same?

    Thanks,
    Dev

  5. Dev
    Dev avatar
    28 posts
    Member since:
    Jan 2011

    Posted 19 Jul 2013 Link to this post

    Hello Megdalena,

    I have resolved it by using


    html .RadTreeView_Default .rtIn {
        width: 97%;
         display:inline-block;
    }

    Thanks for your kind support. :)

    Thank you,
    Dev
  6. Magdalena
    Admin
    Magdalena avatar
    421 posts

    Posted 22 Jul 2013 Link to this post

    Hi Devendra,

    I am glad that you have resolved the problem. 
    Do not hesitate to contact me if you have other questions.

    Regards,
    Magdalena
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017