I'm using the new Microsoft ASP.NET Ajax Combobox control.
But I want to use HTML-Tags for formatting in the DropDownlist.
It renders to <ul>
and <li>
and not to <select>
and <option>
, so it should be possible.
My Control looks like this:
<act:ComboBox ID="cbxCompany" runat="server" Width="180" AutoCompleteMode="Append" CssClass="ComboBoxStyle" />
In the Code behind I do this:
cbxTyp.Items.Insert(0, New ListItem("<b>This is<b> formatted Text", "1"))
cbxTyp.Items.Insert(0, New ListItem("And now, an icon: <img src='icon.gif' />", "2"))
But the HTML-Code appears encoded.
Is it possible to use HTML tags? An attribute like "allowHTML" would be helpful.