C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




Change text color programatically in C#


Posted Date: 05 Sep 2008      Total Responses: 2

Posted By: Frank Malola       Member Level: Gold     Points: 1



Hi,

I would like to change the text color programatically in C#.

I will appreciate your help.

Regards,
Gundi







Responses

Author: Ramesh    05 Sep 2008Member Level: SilverRating:     Points: 3

Hi,

Do you mean to say, changing the text colour of a label?
Then heres the code

System.Drawing.Color clr;
clr = Drawing.Color.Blue;
label1.Font.Color = clr;

Thanks,
Ramesh



Author: Gaurav Agrawal    05 Sep 2008Member Level: DiamondRating:     Points: 3

Hi this is easy to do this

first of all u will use label or div or table or panel any thing and then use this

label1.forecolor = system.drawing.color.red;

div.Style.Add("color", "Red");

This can be done what u want....

GA



Post Reply
You must Sign In to post a response.
Next : doubts abt collections in C#.Net
Previous : How to capture portion of image that is within a selection rectangle?
Return to Discussion Forum
Post New Message
Category: .NET

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design


Contact Us    Privacy Policy    Terms Of Use