Click here to Skip to main content
11,642,216 members (67,138 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#3.0
hi

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
Edited 23-Dec-10 18:19pm
Not Active10.2K
v3
Comments
Walt Fair, Jr. at 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 at 24-Dec-10 12:57pm
   
Absurdity!
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
good
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.
  Permalink  

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



Advertise | Privacy | Mobile
Web04 | 2.8.150731.1 | Last Updated 24 Dec 2010
Copyright © CodeProject, 1999-2015
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