Hi, I am using KendoMobileListView and I want to know how I can get the index of selected Item. My DataSource contains multiple entries and I want to be able to find out the index of selected item to show appropriate data
I dont think this is the right way to get the index of selected item because i am keep getting and error saying :
Uncaught TypeError: Object [object Object] has no method 'select'
Any Idea how I can go about doing this ? Thank you
$('#Template').kendoMobileListView({ dataSource: EmployeeVisitsInfo, template: '<table style="width: 100%"><tr><td><p>${a = (typeof data.Name !== "undefined") ?Name : data.LastName</td></table>', click: function(e){ var datasource = $('#Template').data("kendoMobileListView"); var index = datasource .select().index(); var dataItem = ds.dataSource.view()[index]; console.log(index) } });I dont think this is the right way to get the index of selected item because i am keep getting and error saying :
Uncaught TypeError: Object [object Object] has no method 'select'
Any Idea how I can go about doing this ? Thank you