Monday, February 18, 2008

Set GridView Header Font Style in CSS

I have defined my GridView header style in CSS. Because I've set my GridView to be sortable, so the header texts will be links, and it'll follow the style of Links as defined.

I'd like to change the header text color to fit to header row color, and finally I've found the solution.

Define the CSS like this:

tr.OrangeGridViewHeader, 
tr.OrangeGridViewHeader a:visited,
tr.OrangeGridViewHeader a:link
{
background-color:#feaa66;
font-family:Verdana;
font-weight: bold;
color:#000;
text-decoration:none;
}

tr.OrangeGridViewHeader a:hover
{
background-color:#feaa66;
font-family:Verdana;
font-weight: bold;
color:#000;
text-decoration:underline;
}



 


Then set the HeaderStyle's CssClass to OrangeGridViewHeader. It's done! Happy

1 comment:

  1. Hello
    http://www.thecenterforenergyhealing.com/ - adipex drug
    Stick to a regular regimen of good diet, exercise and the diet pill recommended by your physician.
    [url=http://www.thecenterforenergyhealing.com/]adipex weight loss[/url]

    Confer with your doctor regarding other medications you are taking especially those related to diabetes as well as hypertensive drugs.
    adipex 37.5
    Your drive plus your dedication to achieve your ideal body weight are all important factors to achieving that goal.

    ReplyDelete