"Frank" <fr*******@advitronic.nlwrote in message
news:B%*******************@en-nntp-04.am2.easynews.com...
I have 3 listboxes on my page, they all contain the same data. How can I
avoid sending the THREE complete lists with data on the webpage? I would
like to sent only 1 list with data and use it in all three listboxes.
Remark, maybe of interest: the listboxes are on 3 different tabs in an
ajax tabcontainer.
Your only real option would be write a piece of client-side JavaScript which
would iterate through the first ListBox's elements collection and add copies
of them to the second and third ListBoxes. However, this would mean that you
would not be able to refer to the second and third ListBoxes in the "normal"
way on postback, since dynamic client-side modifications to ListBox elements
don't get persisted on postback because they're not in ViewState. Instead,
you'd need to reference something like Request.Form["MySecondListBox"], cast
it to a ListBox object and then inspect it....
Unless the lists are huge, I wouldn't even bother...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net