I have two Listboxes in my ASPX page. On page load the first listbox(lballcolumns) lists all the items from the db after loading all items using the below code I am removing the items that all already in the second Listbox(lbselected).
for (int i = lbselectedColumns.Items.Count-1; i >= 0; i--)
But somehow last item is not getting removed. For eg. if First Name is the last column in my dbtable, that is not getting removed. What may be the reason.