I have been trying to solve this since last week. I am using JUnit with Selenium which is used for testing user interfaces. So this problem of mine can also be related to css, html, and javascript since these are the technologies I used in making the user interface. I posted it here because Selenium is used in Java.

We can set a "DIV" tag to automatically have a scrollbar when it overflow by using css.

My problem is I need the scrollbar to scrolldown and scrollup.

The content of the DIV is long that is the reason I need it to scrolldown.

Got any ideas? Is there anyone here who experienced the same?