Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
.NET Color setting blues
Message
From
16/02/2007 09:37:21
 
 
To
All
General information
Forum:
ASP.NET
Category:
Other
Title:
.NET Color setting blues
Environment versions
Environment:
ASP.NET
Miscellaneous
Thread ID:
01196502
Message ID:
01196502
Views:
52
Why does MS make seemengly easy things so difficult, or am I the only one that doesn't get it?

I am required to set all text (e.g. a Hyperlink) to a special shade of blue:
System.Drawing.Color SpecialBlue = System.Drawing.Color.FromArgb(0, 35, 160);
How do you set it?
HyperLink hlModuleName = new HyperLink();
//hlModuleName.ForeColor  <== what goes here?
You'd think that you could set it in text? Nope. Or assign the system color created above? Nope
There is a ToArgb() method, but it does not have a FromArgb() or any way I can see to set this thing.
Am I missing something obvious here? Or has MS deliberately made color setting in an ASP.NET control overly obtuse on purpose?


Alex Feldstein, MCP, Microsoft MVP
VFP Tips: English - Spanish
Website - Blog - Photo Gallery


"Once again, we come to the Holiday Season, a deeply religious time that each of us observes, in his own way, by going to the mall of his choice." -- Dave Barry
Next
Reply
Map
View

Click here to load this message in the networking platform