Solved

Style sheet for combo box

Posted on 2003-12-05
5
943 Views
Last Modified: 2010-04-09
Dear all,
I change window's scroll bar to this :
SCROLLBAR-HIGHLIGHT-COLOR: #99ccff; SCROLLBAR-SHADOW-COLOR: #99ccff; SCROLLBAR-3DLIGHT-COLOR: #99ccff; SCROLLBAR-TRACK-COLOR: #d7ebff; SCROLLBAR-DARKSHADOW-COLOR: #99ccff; SCROLLBAR-BASE-COLOR: #ffffff;

How can change scroll bar for combobox (list box) to the same.

Thanks.
0
Comment
Question by:ethar1
  • 2
  • 2
5 Comments
 
LVL 33

Expert Comment

by:hongjun
ID: 9887338
An example

<select name="selDay" style="background: Silver; color: Maroon; font-family: Arial; font-size: x-small; border-style: none;">


hongjun
0
 
LVL 33

Expert Comment

by:hongjun
ID: 9887339
0
 
LVL 31

Accepted Solution

by:
seanpowell earned 500 total points
ID: 9887966
Hi ethar1,

I'm afraid you cannot change the color of the scrollbar in a select box. It is set by the Operating System.

Thanks,
georgemarian
0
 
LVL 8

Expert Comment

by:nishikanth
ID: 9910445
place this between the <head></head> tags

Code:

<style type="text/css">
BODY {
 scrollbar-face-color:"#800000";
scrollbar-arrow-color:"#808080">;
scrollbar-track-color:"#000000";
scrollbar-shadow-color:"#003366";
scrollbar-highlight-color:"#660066";
scrollbar-3dlight-color:''660066";
scrollbar-darkshadow-Color:"#";
}
</style>


-----------------------------------------------------------------------------

This is changing it with styles, you can link to an external style sheet to update all your pages at once

<style type="text/css">
BODY {
      SCROLLBAR-BASE-COLOR: #1293ee;
      SCROLLBAR-ARROW-COLOR: #FFFFFF;
}
SELECT {
      FONT-FAMILY: Verdana,Arial,Helvetica,sans-serif;
      FONT-SIZE: 11px;
      COLOR: #000000;
      BACKGROUND-COLOR: #CFCFCF
}
TEXTAREA, .bginput {
      FONT-SIZE: 12px;
      FONT-FAMILY: Verdana,Arial,Helvetica,sans-serif;
      COLOR: #000000;
      BACKGROUND-COLOR: #CFCFCF
}....

-----------------------------------------------------------------------------------


FYI - you can even use more properties:

{
background-image: url('../images/bg.gif');
background-color: #D7DFE9;
scrollbar-arrow-color: #375A83;
scrollbar-3dlight-color: #8D9FC0;
scrollbar-highlight-color: #8D9FC0;
scrollbar-face-color: #D7DFE9;
scrollbar-shadow-color: #8D9FC0;
scrollbar-darkshadow-color: #8D9FC0;
scrollbar-track-color: #ACB8C5;
}



0
 
LVL 31

Expert Comment

by:seanpowell
ID: 9911925
The question was how to change the scrollbar color for the "select" box. Not the window scrollbar. Without creating a dhtml select box (that may or may not function properly within a form environment) it cannot be done. It is set by the Operating System.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
html select on change 3 25
Syntax Error 6 32
Datepicker in PHP 9 21
Bootstrap more than 12 columns in row 3 6
This is a PowerShell web interface I use to manage some task as a network administrator. Clicking an action button on the left frame will display a form in the middle frame to input some data in textboxes, process this data in PowerShell and display…
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how to define a gradient in CSS. Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Gradient. Define the background as "linear-gradient(to right, #ee3668, black)". Ensure you …
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now