sherlock1305
Programmer
Hi,
first, sorry for my english, it's not my first language!
Here is my question.
Is there a way to control the scroll bar when clicking on it???
I've tried this code...
<SCRIPT>
function ComponentSnapShot(){
var sElem = "";
sElem = document.body.componentFromPoint(event.clientX, event.clientY);
if (sElem=="scrollbarDown"
{
window.scrollBy(0,1200);
// alert("1"
}
if (sElem=="scrollbarUp"
{
window.scrollBy(0,-1200);
// alert("2"
}
if (sElem=="scrollbarPageDown"
{
window.scrollBy(0,20);
// alert("3"
}
if (sElem=="scrollbarPageUp"
{
window.scrollBy(0,-20);
// alert("4"
}
}
</SCRIPT>
</HEAD>
<BODY onmousedown=ComponentSnapShot() LANGUAGE=javascript>
...but it just works with "Alerts"?!?!?
Does anyone know why?
...or anyone has another solution???
Thanks a lot.
Sherlock
first, sorry for my english, it's not my first language!
Here is my question.
Is there a way to control the scroll bar when clicking on it???
I've tried this code...
<SCRIPT>
function ComponentSnapShot(){
var sElem = "";
sElem = document.body.componentFromPoint(event.clientX, event.clientY);
if (sElem=="scrollbarDown"
{
window.scrollBy(0,1200);
// alert("1"
}
if (sElem=="scrollbarUp"
{
window.scrollBy(0,-1200);
// alert("2"
}
if (sElem=="scrollbarPageDown"
{
window.scrollBy(0,20);
// alert("3"
}
if (sElem=="scrollbarPageUp"
{
window.scrollBy(0,-20);
// alert("4"
}
}
</SCRIPT>
</HEAD>
<BODY onmousedown=ComponentSnapShot() LANGUAGE=javascript>
...but it just works with "Alerts"?!?!?
Does anyone know why?
...or anyone has another solution???
Thanks a lot.
Sherlock