
 function sticky(resultsPerPage, resultsFormat){
    var thisElement;

    thisElement = document.forms[0].numrecs;

    for (var i = 0; i < thisElement.length; i++) {
       if (thisElement.options[i].text == resultsPerPage)
          thisElement.selectedIndex = i;
    }

    thisElement = document.forms[0].fmtclass;
    for (var i = 0; i < thisElement.length; i++) {
       if (thisElement.options[i].value == resultsFormat)
          thisElement.selectedIndex = i;
    }
 }

 function logicalSearch(databaseName) {
   if ("Logical" == databaseName) {
      if (document.forms[0]) {
         if (document.forms[0].dbname[0]) {
            for (i = 0; i < document.forms[0].dbname.length; i++ ) {
                document.forms[0].dbname[i].checked=true;
            }
         }
      }
   }
}

function setfocus() {
   window.onerror = null;
   window.focus();
   if (document.forms[0]) {
      if (document.forms[0].elements[0].type == "text" || 
      document.forms[0].elements[0].type == "password") {
         document.forms[0].elements[0].focus();
	 if (document.forms[0].elements[0].value != "") {
             document.forms[0].elements[0].select();
         }
      }
   }
}

function named_setfocus(name) {
   window.onerror = null;
   window.focus();
   if (document.forms[0].elements) {
     var object = eval("document.forms[0]." + name);
     object.focus();
     if (object.value != "") {
        object.select();
     }
   }
}


