CodeVerge.Net Beta


   Explore    Item Entry   Register  Login  
Microsoft News
Asp.Net Forums
IBM Software
Borland Forums
Adobe Forums
Novell Forums

ASP.NET Web Hosting – 3 Months Free!



Zone: > NEWSGROUP > Asp.Net Forum > general_asp.net.master_pages_themes_and_navigation_controls Tags:
Item Type: NewsGroup Date Entered: 3/31/2008 7:13:17 PM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 3 Views: 61 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
4 Items, 1 Pages 1 |< << Go >> >|
bendJoe
Asp.Net User
TreeNode text color3/31/2008 7:13:17 PM

0/0

Hi,

I wanted to set the text of a treeview node . I tried the following but is not working. 

trNode.Text = "<font color='GREEN'>" + tempCaseStage.StageName.Trim () + "</font>";

What is wrong here?

Thanks 

SGWellens
Asp.Net User
Re: TreeNode text color3/31/2008 10:48:18 PM

0/0

Where are you executing the code?  This worked:

    protected void TreeView1_Load(object sender, EventArgs e)
    {
        TreeView1.Nodes[0].Text = "<font color='Red'>Red</font>"; 
        TreeView1.Nodes[1].Text = "<font color='Blue'>Blue</font>";
        TreeView1.Nodes[2].Text = "<font color='Green'>Green</font>";    
    }
 
Steve Wellens
bendJoe
Asp.Net User
Re: TreeNode text color4/1/2008 10:05:36 PM

0/0

 I am adding the treeview nodes by code.

   trNode.Text = "<font color='GREEN'><strong>" + tempCaseStage.StageName + "</strong></font>";       
                

  Tree.Nodes.Add(trNode);

Thanks 

SGWellens
Asp.Net User
Re: TreeNode text color4/1/2008 10:33:56 PM

0/0

It should work.

Does tempCaseStage.StageName have any text in it?  If it's blank, nothing will display in the TreeNode.


Steve Wellens
4 Items, 1 Pages 1 |< << Go >> >|


Free Download:

Books:
Pro ASP.NET 2.0 in VB 2005: From Professional to Expert Authors: Laurence Moroney, Matthew MacDonald, Pages: 1253, Published: 2006
.NET Windows Forms in a Nutshell: A Desktop Quick Reference Authors: Ian Griffiths, Matthew Adams, Pages: 879, Published: 2003
Professional C# 2008 Authors: Christian Nagel, Bill Evjen, Jay Glynn, Karli Watson, Morgan Skinner, Pages: 1782, Published: 2008
Sams Teach Yourself .NET Windows Forms in 21 Days Authors: Chris Payne, Chris Payne כריס. פין, Pages: 883, Published: 2002
Professional C# 2005 Authors: Christian Nagel, Bill Evjen, Jay Glynn, Karli Watson, Morgan Skinner, Allen Jones, Pages: 1540, Published: 2006
IEEE Symposium on Information Visualization: Proceedings, October 19-20, 1998, Research Triangle Park, North Carolina, USA Authors: Graham Wills, John Dill, IEEE Computer Society Technical Committee--Computer Graphics, IEEE Xplore (Online service), Pages: 162, Published: 1998
Microsoft.NET Compact Framework: Kick Start Authors: Erik Rubin, Ronnie Yates, Pages: 578, Published: 2003
Pro C# with .NET 3.0: exploring the .NET universe using curly brackets Authors: Andrew Troelsen, Pages: 1186, Published: 2007
Effective GUI Test Automation: Developing an Automated GUI Testing Tool Authors: Kanglin Li, Mengqi Wu, Pages: 445, Published: 2004
Pro C# 2005 and the .NET 2.0 Platform: Public Beta Edition Authors: Andrew W. Troelsen, Pages: 982, Published: 2005

Web:
TreeNode.Text Property (System.Windows.Forms) Gets or sets the text displayed in the label of the tree node. ... ForeColor = Color.Orange ' Store the Customer object in the Tag property of the TreeNode. ...
set treenode text color w/ cls at config - Ext JS Forums Did u get any solution to that treenode text color issue??? If so, pls let me know, i am struggling with the same problem. Thanx in adance. ...
TreeNode text color - ASP.NET Forums Text = "" + tempCaseStage.StageName.Trim () + ""; ... If it's blank, nothing will display in the TreeNode. ...
TreeNode.Text color customization - ASP.NET Forums i need to customize treenode text with different colors in treeview web controls . i extended TreeNode class and overrided RenderPreText as ...
Change TreeNode.Text before editing - bytes TreeNode.Text = "TestNode {ShortCut}"; ... You can find an article concerning this here:[/color] ... Johnny Thawte wrote:[color=green] ...
Change TreeView, treenode background color - ASP.NET Forums Text = "
" + node.Text + "</div>"; } foreach ( TreeNode childNode in node.ChildNodes) { if (childNode. ...
TreeNode.BackColor Property (System.Windows.Forms) Dim instance As TreeNode Dim value As Color value = instance.BackColor instance. ... Text + " " countIndex += 1 Else myNode.BackColor = Color. ...
ASP.NET Tree : ExpertTree Demo ... Exploring the Internet Explorer WebControls :: DotNetJohn Feb 23, 2003 ... DefaultStyle="background: #CCCCCC; border: solid 1px; color: Black; font-size: 10pt" /> Change the treenode font size and color at runtime NET AJAX: TreeView / Change the treenode font size and color at runtime ... Text == "Node1"). {. node.ForeColor = System.Drawing.Color.Red; ...




Search This Site:










how to stop a treeview from flashing after clicking a node?

treeview node display question

problem with imageurl defined in a skin file

master page ... child page ... add a child page specific stylesheet?

client script for a menuitem

adding nodes to a sitemap at runtime

changing cssclass of label in a masterpage with content page script.

specific css stylesheet to associate with skinfile

what's the wrong with master page and postback ?

keeping menu item selected when going into child nodes

can u have more than one web.sitemap file for a website.

horizontal menu...pls help

master page losing page_load events on content page transactions

the new asp:menu control (orientation on sub-menu items)

problem with staticmenustyles on menu control

themes & localization

how to set the visible for asp:menuitem

script manager on my master page

is it possible to cache a master page ?

validation with a tree view/form view

menu not displaying on content pages

master & content page

menu control - dynamicmenustyle not rendering correctly when specifying css

"client id could not found error" when use custom control for validation

themes not working in redirectfromlogin page

master pages and mobile web forms

asp:menu customizing and hiding items

asp menu and cssclass property

findcontrol in a menu's staticitemtemplate

javascript in master pages

  Privacy | Contact Us
All Times Are GMT