ASP.NET ComboBox - Load Items with Icons from Database
Alfreds Futterkistee555
ALFKI
Ana Trujillo Emparedados y helados
ANATR
Antonio Moreno Taquería
ANTON
Around the Hornn
AROUT
Berglunds snabbköp
BERGS
Blauer See Delikatessen
BLAUS
Blondel père et fils
BLONP
Bólido Comidas preparadas
BOLID
Bon app'
BONAP
Bottom-Dollar Markets
BOTTM
The items of the ComboBox can contain an icon next to the text.
The source of this image is specified using the
ImageUrl
property.
The icon of the selected item can be displayed in the input field of the ComboBox,
by setting the
ShowSelectedImage
property to
true
.
You can display icons for items even when the ComboBox is populated from a data source control.
In this case, the
ImageUrl
for each item can be set in the event handler of the
ItemDataBound
event.
« Back to examples