logo

New Response

« Return to the main article

You are replying to:

  1. Thought I would add this here... cause I came here looking for solution to this problem. Hope it helps others.

    Prob in notes when you do a web refresh - ie to calculate the value of a field based on other conditions the page will jump - either to the top of the page (bad) or bring the field you are working on to the top (only slightly better than the other option)

    so... how to fix

    Fix

    instead of using the field property "Refresh fields on keyword change" you use an onclick or an onchange event and use some code like

    _doClick('$Refresh',this,null);

    this will refresh the page but you still have a problem with the jump but at least you control the code not domino then

    use these javascript functions to capture the current scroll position

    function storePos(){ document.cookie = "win_"+window.name+"="+document.body.scrollTop; } function lastPos(){ cVal = document.cookie.split("win_"+window.name+"="); if(cVal.length==2){ window.scrollTo(0,parseInt(cVal[1])); } }

    put this in the JSheader or wherever you normally put your JS

    lastly you need to place

    <body onLoad="lastPos()" onScroll="storePos()">

    in the body note that we have onLoad but no onScroll in domino so I just whack it in in pass-through HTML and domino copes fine

    so what happens is on the field being clicked it gets refreshed... and the current postion is always tracked so the refresh leaves you at the right place

    cheers luc

Your Comments

Name:
E-mail:
(optional)
Website:
(optional)
Comment: