Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Controls / February 2008

Tip: Looking for answers? Try searching our database.

.Net 2 Web Panel Font Colour

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Waldy - 13 Feb 2008 16:07 GMT
Hi there,
            how do you set the colour of a Panels text via CSS.  Neither
Color, ForeColor nor Font-Color work in a CSS file.  It is set to grey /
blue colour.  Is this fixed by the system?
Waldy - 13 Feb 2008 16:20 GMT
I should mention that I am trying to set the GroupingText of the Panel.
There are three colour properties for this control.  BackColor, BorderColor
and ForeColor.  ForeColor does affect labels that are dropped onto the
Panel, but not the GroupingText.  BorderColor does not seem to have any
effect on anything.
Phil H - 13 Feb 2008 20:02 GMT
> I should mention that I am trying to set the GroupingText of the Panel.
> There are three colour properties for this control.  BackColor, BorderColor
> and ForeColor.  ForeColor does affect labels that are dropped onto the
> Panel, but not the GroupingText.  BorderColor does not seem to have any
> effect on anything.

GroupingText should assume the ForeColor (is does in my case).

BorderColor should affect the outline around the panel (make sure
BorderStyle and BorderWidth are also set)

If you've been experimenting with CSS styles it maybe that they are
interfering in some way and you need to remove any references.
Waldy - 14 Feb 2008 12:03 GMT
>GroupingText should assume the ForeColor (is does in my case).

Yes it should but it doesn't.  Neither the ForeColor property or the CSS
color attribute have any effect on it.

>BorderColor should affect the outline around the panel (make sure
BorderStyle and BorderWidth are also set)

That's correct.  It only effects the border around the panel, not the
grouping border which appears to be fixed colour and style.
Waldy - 14 Feb 2008 12:46 GMT
I found some info on this.  Here's how to set your text and border to red.

If you set your Panel class name to clsPanel.

Then add the following to the CSS file:

.clsPanel legend
{
   color: red;
}

.clsPanel fieldset
{
   border: solid 1px red;
}

The legend tag applies the style to the GoupingText and the fieldset tag
applies the style to the GroupingBorder.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.