node text indentation

2 posts, 0 answers
  1. mdk
    mdk avatar
    24 posts
    Member since:
    May 2007

    Posted 17 Feb 2010 Link to this post

    Hey guys,
    Is there a way to to set indentation of a node with sub nodes so that it's expand/collapse icon is flush left with the text of nodes that do not have sub nodes?
    Thanks in advance,
  2. Yana
    Yana avatar
    4547 posts

    Posted 19 Feb 2010 Link to this post

    Hi mdk,

    It can be achieved like this:

    <telerik:RadTreeView ID="tree1" runat="server" ShowLineImages="false">
            <telerik:RadTreeNode Text="root">
                    <telerik:RadTreeNode Text="node 1" />
                    <telerik:RadTreeNode Text="node 2" />
                    <telerik:RadTreeNode Text="node 3" />
                    <telerik:RadTreeNode Text="node 4" />
                    <telerik:RadTreeNode Text="node 5" />
            <telerik:RadTreeNode Text="root node 2" ContentCssClass="noChilds" />
            <telerik:RadTreeNode Text="root node3" ContentCssClass="noChilds" />

    and the used "noChilds" css class:

    .noChilds  {
        padding-left: 0 !important;

    Kind regards,
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. DevCraft R3 2016 release webinar banner
Back to Top