In my ASP.NET application I have two listboxes, say Listbox1 and Listbox2. Listbox1 having some listitems and which is in Multiple Selection Mode. If I Press the transfer button the selected items in Listbox1 should be moved to Listbox2. I have tried it for Single Selection Move and it works fine. Now I need help for multiselection.
Code for Single Selection
strItemText = lstAvailableItems.SelectedItem.Text
iItemCode = lstAvailableItems.SelectedValue
lstAvailableItems.Items.Remove(New ListItem(strItemText, iItemCode))
lstSelectedItems.Items.Add(New ListItem(strItemText, iItemCode))
Listbox image
If I press the > button single selected item will be moved from Available Items listbox to selected items list box. How to do this for multiple selection?