Hendrik Otting: scrollbarposition abfragen

Hallo Forum

Im Forumsarchiv : http://www.teamone.de/selfhtml/sfarchiv/1999_2/t03158.htm#a15091
stand schon mal was kurzes über scrollbarpositionen.
Wollt ich auch gleich mal einbauen, um meine popuphilfen auch im sichtbaren Bereich erscheinen zu lassen.

Hab mir da sowas gedacht :

function sethelptimer(str){
helptimer=true;
abbruch = window.setTimeout("help('"+str+"')",1000); // 1sec warten mit popup
}
function clearhelp(){
helptimer=false;
window.clearTimeout(abbruch);
hide(divnamefuerhilfe);
}
function help(str){
str = '<table bgcolor="'+farbevonpopup+'" width='+maxbreitefuerhilfe+'><TR><TD>'+str+'</TD></TR></table>'
if(parent.frames[framefuerhilfe].pageXOffset > 0) mouseposx = mouseposx-parent.frames[framefuerhilfe].pageXOffset;
if(parent.frames[framefuerhilfe].pageYOffset > 0) mouseposy = mouseposy-parent.frames[framefuerhilfe].pageYOffset;
if(parent.frames[framefuermenu].pageXOffset > 0) mouseposx = mouseposx-parent.frames[framefuermenu].pageXOffset;
if(parent.frames[framefuermenu].pageYOffset > 0) mouseposy = mouseposy-parent.frames[framefuermenu].pageYOffset;
if (helptimer) {
  writediv(framefuerhilfe,divnamefuerhilfe,str);
  show(divnamefuerhilfe);
  }
}
tja nur funktionieren tut noch nicht mal die x-richtung...

mfg
      Hendrik