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

Find and updating item

1 Answer 13 Views
ListView
This is a migrated thread and some comments may be shown as answers.
Ino
Top achievements
Rank 1
Ino asked on 29 Oct 2015, 09:56 PM

I have tried to locate a solution for this but not been able to find a clear solution

 What i am trying to do is

I got at kendolistview with template, defined as "<li>sometext</li>, on a <ul> and getting data from webservice defined {ID,Name}

I then got SignalR Event that calls function on page sometimes with an ID and in this function i have to somehow get the relevant item from the listview and change etc. innerHTML on that item

 

Should be simple i think... Or maybe i am using the wrong tools for this?

1 Answer, 1 is accepted

Sort by
0
Accepted
Kiril Nikolov
Telerik team
answered on 02 Nov 2015, 12:44 PM

Hello Ino,

 

You can set the id as a data attribute in the template, so you can use a jQuery selector to get the element, and then perform the manipulations. For example:

$("[data-id=yourIdHere]")

 

Regards,
Kiril Nikolov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
ListView
Asked by
Ino
Top achievements
Rank 1
Answers by
Kiril Nikolov
Telerik team
Share this question
or