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

Listview - dataBound event not firing

5 Answers 211 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Jan-Dirk
Top achievements
Rank 1
Jan-Dirk asked on 07 May 2013, 12:10 PM
I am using the dataBound event as described here: http://docs.kendoui.com/api/mobile/listview#events-dataBound

It seems I can't get it to fire.

This is my code (i have removed some irrelevant code in the click event):

$("#projectsList").kendoMobileListView({
    dataBound: function(e) {
        console.log('databound event fired!');
     },
    click: function (e) {
        console.log("click event fired");
    },
    template: $("#projectsListTemplate").html(),
    dataSource: dsProjects,
    endlessScroll: true,
    scrollTreshold: 10
});

I am not getting the 'databound event fired' in my console.

I have tried to set up a quick jsfiddle, but couldn't get that to work at all.


5 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 07 May 2013, 04:34 PM
Hi JD,

Do you mean everything works in the jsfiddle sample or it does not work there as well? If the latter, there must be something specific in your app to cause the problem, can you share which app is that on, so we can check it?

All the best,
Steve
the Telerik team

Share feedback and vote for features on our Feedback Portal.
Want some Kendo UI online training - head over to Kendo UI Dojo.
0
Jan-Dirk
Top achievements
Rank 1
answered on 07 May 2013, 06:07 PM
Thank you for your reply Steve,

I wanted to see if I could isolate the problem in a jsfiddle, but I couldn't get the listview showing at all. Also, I didn't want to reveal too much code because I don't want to expose the webservices I am using.

The problem is in my K1ckstart3r-project, feel free to have a look at it. You will find the code in js/application.js at line 149.

Thanks again for your help!
0
Jan-Dirk
Top achievements
Rank 1
answered on 08 May 2013, 06:24 PM
btw, I am using Kendo UI mobile v2012.3.1114
0
Steve
Telerik team
answered on 09 May 2013, 02:55 PM
Hello JD,

After advising with our Kendo colleagues for expert Kendo UI help, they've outlined three things that are the root cause for your problems:
  • duplicating initialization of widgets - via data attributes and via jQuery plugin calls
  • initialization of widgets in wrong events i.e. view show events
  • last but not least, the version of Kendo UI mobile v2012.3.1114 is pretty old and buggy.

The approaches from the first two points have never been supported or shown in Kendo examples. The suggestion given was to modify your application accordingly using the following examples as starting point:

  • http://demos.kendoui.com/sushi/
  • http://www.kendoui.com/code-library/mobile/listview/listview---hierarchy.aspx

Kind regards,
Steve
the Telerik team

Share feedback and vote for features on our Feedback Portal.
Want some Kendo UI online training - head over to Kendo UI Dojo.
0
Jan-Dirk
Top achievements
Rank 1
answered on 24 May 2013, 08:11 AM
A bit late, but still thank you for your reply Steve.
Tags
General Discussions
Asked by
Jan-Dirk
Top achievements
Rank 1
Answers by
Steve
Telerik team
Jan-Dirk
Top achievements
Rank 1
Share this question
or