How to avoid scroll on treeview

4 posts, 0 answers
  1. pnr
    pnr avatar
    26 posts
    Member since:
    Jan 2007

    Posted 29 Sep 2008 Link to this post

    Isn’t it possible to disable scroll on the treeview. I like to expand vertical and move the other elements on the side. On the horizontal I like to set a width and the values in the node shall break if they are too long.
  2. Atanas Korchev
    Admin
    Atanas Korchev avatar
    8462 posts

    Posted 29 Sep 2008 Link to this post

    Hi pnr,

    You can use the style property of the treeview (don't set Width or Height)

    <telerik:RadTreeView style="overflow-x:auto;width:300px">

    Regards,
    Albert
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. pnr
    pnr avatar
    26 posts
    Member since:
    Jan 2007

    Posted 29 Sep 2008 Link to this post

    Hi and thanks for your answer but I can’t make I work:

    I have got the following code:


    <radT:RadTreeView  
        ID="venstremenu_rad"   
        Skin="venstremenu"   
        runat="server"   
        style="overflow-x:auto;width:150px"   
        ShowLineImages="false"                               ImagesBaseDir="~/Images/NoLineImages/Images/">  
    </radT:RadTreeView> 

    And it render like this:

    http://www.proff-art.dk/images/menu.jpg

     

     

     

  4. Atanas Korchev
    Admin
    Atanas Korchev avatar
    8462 posts

    Posted 29 Sep 2008 Link to this post

    Hello pnr,

    Which version of RadTreeView are you using? You have posted in the "RadTreeView for ASP.NET Ajax" forum while it looks as if you are using RadTreeView classic. Try this workaround for RadTreeView classic:

                    <div style="width:100px;overflow-x:auto;overflow-y:hidden">
                    <rad:RadTreeView
                        ID="RadTree1"
                        runat="server"
                        ShowLineImages="false"
                        style="overflow:visible;"
                        >
                         </rad:RadTreeView >
                     </div>
    Regards,
    Albert
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top