This is a migrated thread and some comments may be shown as answers.

[Solved] need line break between node text

4 Answers 223 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
sathish venkat
Top achievements
Rank 2
sathish venkat asked on 02 Mar 2010, 08:48 PM

“I am not able to give line break to the node text. It is display in single line

But I need to display node text as two lines. Can you please tell me the solution to solve this issue “

4 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 03 Mar 2010, 06:13 AM
Hi Sathish,

Try adding <br /> tag between the Node text to show the it as next line.

ASPX:
 
    <telerik:RadTreeNode runat="server" Text="Child <br /> RadTreeNode 1"
    </telerik:RadTreeNode> 

Regards,
Shinu.

0
sathish venkat
Top achievements
Rank 2
answered on 03 Mar 2010, 12:24 PM
Hi,
    Thanks for your reply but i would not do this because i am binding treenode as dynamically. node text is coming from database
i don't know the length of the text
0
Accepted
Yana
Telerik team
answered on 04 Mar 2010, 03:28 PM
Hello Sathish,

You should set Width property of the treeview and add the following css style to your page:

<style type="text/css">
    div.RadTreeView {
        white-space:normal;
    }
</style>


All the best,
Yana
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.
0
sathish venkat
Top achievements
Rank 2
answered on 04 Mar 2010, 04:57 PM
Thanks its working fine
Tags
TreeView
Asked by
sathish venkat
Top achievements
Rank 2
Answers by
Shinu
Top achievements
Rank 2
sathish venkat
Top achievements
Rank 2
Yana
Telerik team
Share this question
or