function setselect(callingframe,arg,inputnumber) { var lookfor = callingframe.document.varvalues.elements[inputnumber].value; var browseobject= callingframe.document.varvalues.elements[inputnumber+3]; var number = browseobject.length; if( number < 1 ) return true; for(var i=0; i < number; i++) { if( browseobject.options[i].text == lookfor ) { browseobject.selectedIndex = i; browseobject.options[i].selected = true; browseobject.options[i].defaultSelected = true; break; } } return true; }