Page view counter

I want my browser scrollbar in desired color

Last post 11-21-2008 3:13 PM by rossisdead. 5 replies.

Sort Posts:

  • I want my browser scrollbar in desired color

    11-20-2008, 8:31 AM
    • Loading...
    • Happies
    • Joined on 09-26-2008, 7:30 AM
    • Posts 151
    • Points 79

     Hi all,

       I want my browser scroll bar in desired color.I used the code below.

    <style type="text/css">
    BODY{
    scrollbar-face-color:#DFFFBF;
    scrollbar-shadow-color:green;
    }
    </style>

    i used this code in masterpagse.i wrote this code before </head>tag
    but it's giving error which is saying that these are not a valid CSS property names

    Can anybody pls help me.

    Cheers Happy.
  • Re: I want my browser scrollbar in desired color

    11-20-2008, 8:39 AM
    Answer
    • Loading...
    • SATISD9X
    • Joined on 04-17-2007, 2:14 PM
    • Mumbai, India
    • Posts 320
    • Points 1,850

    You can very well achieve this using CSS

     Apply the following CSS to your BODY and then see

    <STYLE TYPE="text/css">

    BODY
    {
    scrollbar-3dlight-color:'';
    scrollbar-arrow-color:blue;
    scrollbar-darkshadow-Color:''; 
    scrollbar-face-color:grey;
    scrollbar-highlight-color:'';
    scrollbar-shadow-color:'';
    scrollbar-track-color:red;

    }
    </STYLE>

    CSR
    ~ Please Mark as Answer if it solves your query ~
  • Re: I want my browser scrollbar in desired color

    11-20-2008, 8:43 AM
    Answer
    • Loading...
    • ankit.sri
    • Joined on 02-27-2008, 7:10 AM
    • Noida
    • Posts 223
    • Points 1,078

     Use the following before the </HEAD>

    <style type="text/css">
    html
        {
            scrollbar-face-color:#DFFFBF;
            scrollbar-shadow-color:green;
        }
    </style>

     The Entire code would look like:

    <%@ Master Language="C#" AutoEventWireup="true" CodeFile="MasterPage.master.cs" Inherits="MasterPages_MasterPage" %>

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">

        <title></title>
        <asp:ContentPlaceHolder id="head" runat="server">
        </asp:ContentPlaceHolder>
        <style type="text/css">
    html
        {
            scrollbar-face-color:#DFFFBF;
            scrollbar-shadow-color:green;
        }
    </style>
    </head>
    <body>
        <form id="form1" runat="server">
        <div>
            <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">
           
            </asp:ContentPlaceHolder>
        </div>
        </form>
    </body>
    </html>

    A fundamental rule in technology says whatever can be done will be done
  • Re: I want my browser scrollbar in desired color

    11-20-2008, 8:55 AM
    Answer
    • Loading...
    • joseabie
    • Joined on 04-07-2008, 4:56 AM
    • Abu Dhabi
    • Posts 284
    • Points 1,016

    <STYLE type="text/css">
    <!--
    BODY {
    scrollbar-face-color: green;
    scrollbar-highlight-color: blue;
    scrollbar-3dlight-color: yellow;
    scrollbar-arrow-color: red;
    scrollbar-track-color: aqua;
    }
    </STYLE>

     

    use this code just under the <BODY> tag..

    its worked for me...

     

     

    please check

  • Re: I want my browser scrollbar in desired color

    11-20-2008, 9:07 AM
    Answer
    • Loading...
    • sharpeffect
    • Joined on 09-18-2008, 4:49 PM
    • Posts 198
    • Points 1,226
    The CSS like this in head tag would work perfectly for IE but in firfox it will not work. 
    <style type="text/css">
    html
        {
            scrollbar-face-color:#DFFFBF;
            scrollbar-shadow-color:green;
        }
    
     Firefox does not support this, and it is unlikely to change as this is a deliberate design decision by the firefox development team. There is no workaround, unfortunately.
  • Re: I want my browser scrollbar in desired color

    11-21-2008, 3:13 PM
    Answer
    • Loading...
    • rossisdead
    • Joined on 11-21-2008, 2:43 PM
    • Posts 20
    • Points 149

     As has been stated by everyone else, the style rules that have been posted will definitely work. The catch is that it will only work in Internet Explorer.

     The scrollbar CSS attributes are Microsoft's own proprietary attributes. They are not standards-compliant, which is why it shows up as an error.

Page 1 of 1 (6 items)