Just want to traverse a listbox's (multi select) items & for those that are
selected extract the displayed text - something like below -
function getSelectedDesc rs(lst)
{
var buf;
var maxItems = lst.length;
for (var i=0; i < maxItems; i++)
{
if (lst.options[i].selected == true)
buf+=lst.option s[i].value; // What goes here?
if(i<(maxItems-1))
buf+=",";
}
return buf;
}
any ideas
thanks
selected extract the displayed text - something like below -
function getSelectedDesc rs(lst)
{
var buf;
var maxItems = lst.length;
for (var i=0; i < maxItems; i++)
{
if (lst.options[i].selected == true)
buf+=lst.option s[i].value; // What goes here?
if(i<(maxItems-1))
buf+=",";
}
return buf;
}
any ideas
thanks
Comment