Hello,
I'm using a grid in a mobile app.
When I scroll down to the bottom of a page and filter a few records, the grid is empty.
Pls take a look at the attached screenshots.
Regards
Axel
I'm using a grid in a mobile app.
When I scroll down to the bottom of a page and filter a few records, the grid is empty.
Pls take a look at the attached screenshots.
Regards
Axel
4 Answers, 1 is accepted
0
Hello Axel,
Iliana Nikolova
the Telerik team
Actually the Grid is filtered, however it is not scrolled back to the top (this is default browser's behavior). If you wish the Grid to be scrolled top when filtered you should hook up to its dataBound event and manually scrollTop().
Regards,Iliana Nikolova
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
axel
Top achievements
Rank 1
answered on 01 Mar 2013, 02:29 PM
Hi iliana,
still empty.
by the way. when i rotate the iPad, the grid is filled.
$("#gridAirlines").kendoGrid({
dataSource: _dsAirlines,
dataBound: function () {
$("#gridAirlines").scrollTop();
},
sortable: true,
selectable: "row",
pageable: {
buttonCount: 5,
pageSize: 50,
info: false
},
filterable: {
extra: false,
messages: {
info: "Show airlines with value that:"
},
operators: {
string: {
startswith: "Starts with"
}
}
},
columns: [{
field: "code",
width: 80,
filterable: true,
title: "Code"
}, {
field: "name",
filterable: true,
title: "Airline"
}]
});
Kind regards
Axel
still empty.
by the way. when i rotate the iPad, the grid is filled.
$("#gridAirlines").kendoGrid({
dataSource: _dsAirlines,
dataBound: function () {
$("#gridAirlines").scrollTop();
},
sortable: true,
selectable: "row",
pageable: {
buttonCount: 5,
pageSize: 50,
info: false
},
filterable: {
extra: false,
messages: {
info: "Show airlines with value that:"
},
operators: {
string: {
startswith: "Starts with"
}
}
},
columns: [{
field: "code",
width: 80,
filterable: true,
title: "Code"
}, {
field: "name",
filterable: true,
title: "Airline"
}]
});
Kind regards
Axel
0
Hi Axel,
I believe the following approach will help to achieve the desired outcome:
Kind regards,
Iliana Nikolova
the Telerik team
I believe the following approach will help to achieve the desired outcome:
- In the Grid's dataBound event get the mobile scroller from .k-grid-content;
- Scroll to top using Kendo UI Mobile Scroller's scrollTo() method.
Kind regards,
Iliana Nikolova
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
axel
Top achievements
Rank 1
answered on 06 Mar 2013, 10:16 AM
Hello,
for the sake of completeness, if you have to navigate to the grid.
var scroller = $(".k-grid-content").data("kendoMobileScroller");
if (!scroller)
return;
scroller.scrollTo(0,-10);
works perfectly.
thank you iliana
for the sake of completeness, if you have to navigate to the grid.
var scroller = $(".k-grid-content").data("kendoMobileScroller");
if (!scroller)
return;
scroller.scrollTo(0,-10);
works perfectly.
thank you iliana