• 0

clearing a dropdownlist


Question

I have a page that lists a number of items drawn from a database. These are displayed in a drop down list. Then, on the same page, you can add a item to the database and the dropdownlist is populated again. The problem is, that it is just appending to it. So I want to clear the Drop Down List before I populate it a second time. Does anyone know how to do this? Here is what I tried to do, but it didn't work:

dim li as listItem
	for each li in DDL.items
     DDL.items.remove(li)
	Next

Link to comment
https://www.neowin.net/forum/topic/155329-clearing-a-dropdownlist/
Share on other sites

1 answer to this question

Recommended Posts

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.