This is a migrated thread and some comments may be shown as answers.

Combobox Template item lost after client operation

0 Answers 35 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Yano
Top achievements
Rank 1
Yano asked on 08 Jun 2018, 09:04 AM

Hello, i have RadCombobox with ItemTemplate (Icon  + Text):

<telerik:RadComboBox ID="rcCombo" runat="server" Width="500" >
    <ItemTemplate>
        <table>
            <tr>
                <td>
                    <span class='<%# DataBinder.Eval(Container.DataItem, "ICON") %>'>
                    </span>
                </td>
                <td>
                    <%# DataBinder.Eval(Container.DataItem, "TEXT") %>
                </td>
            </tr>
        </table>
    </ItemTemplate>
</telerik:RadComboBox>

 

and i made reorderig at first posision in Client via javascript

var combo = $find("<%= rcCombo.ClientID %>");
var items = combo.get_items();
combo.trackChanges();
var comboItem = combo.findItemByValue('value');
items.insert(0, comboItem);
comboItem.highlight();
combo.updateClientState();
combo.commitChanges();

 

and after repositioning of comboitem ItemTemplate is not showing - no ICON only simple Text.

Do i need to create ClientItemTemplate for repositioned items or any recomendation?

thanks

No answers yet. Maybe you can help?

Tags
ComboBox
Asked by
Yano
Top achievements
Rank 1
Share this question
or