Click here to Skip to main content
13,095,921 members (52,005 online)
Rate this:
Please Sign up or sign in to vote.
See more:

i am srinivas. i am storing string value into session.

how can i change color in string value

string createuser = Convert.ToString(Session["createuser"]);

i want

Createuser - "Session value";

i want session value red color

please help me
Posted 23-Dec-10 18:04pm
Updated 23-Dec-10 18:19pm
Not Active10.2K
Walt Fair, Jr. 24-Dec-10 0:32am
Where will the string be displayed? That's where you need to look to find out how to set its display characteristics, such as color.
Toli Cuturicu 24-Dec-10 12:57pm
By the way, what color does the number 14 have? Is it blue? What about letter Y. It must be green!

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

You seem very confused. A string is simply an array of characters, more pointedly a memory address, it does not store any information about color, fonts, etc. Wherever the string is rendered, a web page, Windows form, printed document, etc is where the color is specified.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web03 | 2.8.170813.1 | Last Updated 24 Dec 2010
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100