Lee wrote:
Knut-Frode Dagestad said:
>>I have a <selectlist in some html code with hundreds of options. Is it
possible to use javascript to jump to the next/previous item in the list?
Yes.
'Yes' is correct answer!
The solution is the following:
<...in the html-code...>
<input type="button" value="Up" onclick="shiftOps(selectname, -1)">
<input type="button" value="Down" onclick="shiftOps(selectname, 1)">
<...in the javascript-code....>
function shiftOps(sEl, n) {
sEl.selectedIndex = sEl.selectedIndex + n;
sEl.focus();
}