|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
select all multiple-select boxi would like to select all cases in a multiple select box by checking a check
box. does anyone have any ideas? thanks I have managed to create a solution to the problem.
You must call a function from an onclick function (e.g. onclick= "selectall([name of selectbox])" of a checkbox. then you need to build a function much like the one below: function selectall(chosen) { var selObj = document.getElementById(chosen); for (var i = 0; i < selObj.options.length; i++) { selObj.options[i].selected = true; } } Show quote "grangey77" wrote: > i would like to select all cases in a multiple select box by checking a check > box. > > does anyone have any ideas? > > thanks |
|||||||||||||||||||||||