Solved

How to use Custom Graphical Scrollbars for a scrolling div, overflow:auto

Posted on 2004-09-29
6
28,688 Views
Last Modified: 2008-05-23
I am trying to use a scrolling div in a cell within a table on my site. It works fine, but wondered how to go about using a custom graphic scrollbar, explained as simply as possible, or code examples given. That is a custom bar as well as custom arrow-up and down.

I would also like the contents of the cell to start scrolling on mouseover the arrow-up or arrow-down but do not know what to look for in learning how to do so.

I have placed in between my HEAD tags:

<style type="text/css" media="screen">
<!--
.scroller {
  display:block;
  position:relative;
  width: auto;
  height: 50px;
  margin:0;
  padding:5px;
  background:inherit;
  color:inherit;
  overflow:auto;
}
-->
</style>

then

<div class="scroller"></div>  within the cell where I have placed the scrollable content (a table).

Any help would be more than welcome!
0
Comment
Question by:freespirit020199
  • 2
6 Comments
 
LVL 5

Accepted Solution

by:
cristy56 earned 43 total points
ID: 12187618
You can try to use Javascript to do the " start scrolling on mouseover the arrow-up or arrow-down" effect.

go to http://www.dynamicdrive.com
there are lots of scripts teaching u how to use JS to made scrolling content effect.

Regards,
Cristy
0
 
LVL 5

Expert Comment

by:cristy56
ID: 12187645
I think this is what u need :
http://www.dynamicdrive.com/dynamicindex2/pagescroller.htm

Cristy
0
 
LVL 1

Assisted Solution

by:MMabatig
MMabatig earned 41 total points
ID: 12205723
Try the following CSS attributes in the CSS definition of the scrollable DIV. Not sure if it will work for a <div>, but it works with the body element in IE.  It doenst seem to work in Firefox, maybe it will set you on the right path.

      scrollbar-arrow-color:#00346b;
      scrollbar-base-color:#5c8cbf;
      scrollbar-3dlight-color:#00346b;
      scrollbar-darkshadow-color:#00346b;
      scrollbar-highlight-color:#c0c0c0;
      scrollbar-shadow-color:#5c8cbf;


Cheers!
-Mark
0
 
LVL 15

Assisted Solution

by:Daydreams
Daydreams earned 41 total points
ID: 12208138
Hi freespirit,

Take a look at this:

http://www.dyn-web.com/dhtml/scroll/  (vertical scroll available)

At that site, you can download all the code from a link on the left.

..they have instructions for onmouseover in a table cell:

http://www.dyn-web.com/dhtml/scroll/scroll-rel.html

(hover your mouse over the small arrows and see the scroll)
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Suggested Solutions

Someone recently asked me about how to display a progress indicator on a page while an iframe is loading. And I remember when I first came across this myself. It was a bit tricky to get my head around, but really, it's very simple. The most impor…
SASS allows you to treat your CSS code in a more OOP way. Let's have a look on how you can structure your code in order for it to be easily maintained and reused.
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

746 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

12 Experts available now in Live!

Get 1:1 Help Now