DropDownList ASP.NET Server Control

The DropDownList control enables item selection from a drop-down ListBox. For example, if your site requires a user to enter their year of birth you can have a DropDownList populated with years ranging from 1900 to present from which the user can select.

Another example would be if your site wanted users to enter their address and, instead of the full state name, only the states' abbreviations—(Washington–WA). You can force them to enter it correctly by making them choose it from the DropDownList.

The DropDownList is the first of the list controls that we will go over. Even though each of the list controls are different in their functionality they are made up of the same guts—the ListItem. The ListItem represents ...

Get Programming Data-Driven Web Applications with ASP.NET now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.