Question

Is there a way of adding an image to a string within a telerik combobox - if so can you point me in the direction of a code snippet or link

I am using the combobox with languagues and want the country flag beside the country name

Was it helpful?

Solution

You can use the ItemTemplate for this:

<telerik:RadComboBox ID="RadComboBox1" runat="server">
    <ItemTemplate>
        <asp:Image ID="Image1" runat="server" ImageUrl='<%# Eval("ImageUrl") %>' />
        <%# Eval("TextColumn") %>
    </ItemTemplate>
</telerik:RadComboBox>

OTHER TIPS

You will find something similar in RadComboBox for ASP.NET AJAX

<telerik:RadComboBox ID="RadComboBox1" runat="server" Skin="Outlook" AllowCustomText="true">
  <Items>
     <telerik:RadComboBoxItem ImageUrl="*Your Image*" Text="RadComboBox" runat="server" >
        </telerik:RadComboBoxItem>
    </Items>
</telerik:RadComboBox>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top