Manage Learn to apply best practices and optimize your operations.

Lock action bar and top of page against scrolling

Prevent buttons from disappearing when the user scrolls down a page.

Don't you hate it that the action bar at the top of a page disappears every time you have to scroll down the page? Well, here is a solution that does not need frames! It enables you to split a form in two parts and lock the top part (which holds the Domino action bar) so that only the bottom part gets a scrollbar.

The solution is based upon DHTML and probably only works properly with Internet Explorer. We use it with ie-5 and up.


The solution is quite simple. In your form, you first create a <div> section that covers the whole document except for the action bar, and we add a scroll bar to it. This is done by adding the following code (pass through HTML) at the place where you want to split your form:

<style>
DIV.documentBody
{
   Height: 0px ;
   Width: 100% ;
   overflow: auto ;
   }
</style>
<div id="Body" class="documentBody"> 

The part of the document before this code will be locked. In case you just want to lock the action bar, place the code right at the beginning of your form.

Finally, you add some code to adjust the size of the <div> area when the page is resized and we disable the scroll function of the page. To do this, you add the following code to the end of the form (again as pass through HTML):

<script>
var bodyElement = document.body.all['Body'] ;

function LayoutBodyElement() { 
 bodyElement.style.posHeight = document.body.offsetHeight -
bodyElement.offsetTop ;
} // LayoutBodyElement

// Initialize everything when the document is ready
function document.onreadystatechange() {
 document.body.scroll = "no" ;
 LayoutBodyElement( ) ;
 // Handle all resize events
 window.onresize = LayoutBodyElement;
} // document.onreadystatechange

</script>

NOTICE that the <div> section is NOT closed with a </div> tag. The reason for this is that now, the attachment details that domino will insert at the end of the page in case the document contains one or more attached files will also be in the <div> section.

Dig Deeper on Lotus Notes Domino Administration Tools

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchWindowsServer

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchDataCenter

SearchContentManagement

Close