I have a ComboBox defined in a grid column as follows:
I also have a function in the code behind that adds a row
Is there a way to add an image to each item so that there's text + image? In the demos, they use ImagePath, but I can't figure out if this property is available when using the combobox in a grid column. Thanks.
<telerik:GridTemplateColumn UniqueName="den_type_id" HeaderText="Den Type"> |
<ItemStyle Width="175" /> |
<ItemTemplate> |
<asp:Label Width="170" CssClass="gridDropDownLabel" runat="server" ID="lbl_den_type_id" Text='<%#DataBinder.Eval(Container.DataItem, "den_type_nm")%>' /> |
</ItemTemplate> |
<EditItemTemplate> |
<telerik:RadComboBox Width="170" MarkFirstMatch="true" Skin="scSkin" EnableEmbeddedSkins="false" DataTextField="den_type_nm" DataValueField="den_type_id" DataSourceID="DenTypeDataSource" ID="dd_den_type_id" runat="server" SelectedValue='<%#Bind("den_type_id") %>' Text="Select a Type" /> |
</EditItemTemplate> |
</telerik:GridTemplateColumn> |
I also have a function in the code behind that adds a row
Private Sub RadGrid1_ItemDataBound(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridItemEventArgs) Handles RadGrid1.ItemDataBound |
If (TypeOf e.Item Is GridEditableItem AndAlso e.Item.IsInEditMode) Then |
Dim item As GridEditableItem = e.Item |
Dim combo As RadComboBox = item.FindControl("dd_den_ldr_id") |
combo.Items.Insert(0, New RadComboBoxItem("Select a Den Leader", "0")) |
End If |
End Sub |
Is there a way to add an image to each item so that there's text + image? In the demos, they use ImagePath, but I can't figure out if this property is available when using the combobox in a grid column. Thanks.