This question is locked. New answers and comments are not allowed.
hi,
I need a functionality similar to this http://demos.telerik.com/kendo-ui/bar-charts/pan-and-zoom but with groupeddatasource.
Also i have the zoom and pan as image buttons outside the chart, so i am planning to something like this
function redrawChart() {
var mddchrt = $("#chart").data("kendoChart");
var mds = mddchrt.dataSource;
if (srtOptSel == "NA") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "NAME", dir: "asc"}]);
} else if (srtOptSel == "ND") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "NAME", dir: "desc"}]);
} else if (srtOptSel == "VA") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "VALUE", dir: "asc"}]);
} else if (srtOptSel == "VD") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "VALUE", dir: "desc"}]);
}
mddchrt.refresh();
}
sorting is working fine. but how do i set the pagesize and page variables for chart with grouped datasource.
If i try to edit this example , http://demos.telerik.com/kendo-ui/bar-charts/grouped-data ,
if i give
dataSource:
{
data: stocksDataSource,
pageSize: 3,
page: 2
}
instead of
dataSource: stocksDataSource
it is not working, how can i make it work
Thanks
I need a functionality similar to this http://demos.telerik.com/kendo-ui/bar-charts/pan-and-zoom but with groupeddatasource.
Also i have the zoom and pan as image buttons outside the chart, so i am planning to something like this
function redrawChart() {
var mddchrt = $("#chart").data("kendoChart");
var mds = mddchrt.dataSource;
if (srtOptSel == "NA") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "NAME", dir: "asc"}]);
} else if (srtOptSel == "ND") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "NAME", dir: "desc"}]);
} else if (srtOptSel == "VA") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "VALUE", dir: "asc"}]);
} else if (srtOptSel == "VD") {
mds.sort([{ field: "GROUP_FLD", dir: "asc" }, { field: "VALUE", dir: "desc"}]);
}
mddchrt.refresh();
}
sorting is working fine. but how do i set the pagesize and page variables for chart with grouped datasource.
If i try to edit this example , http://demos.telerik.com/kendo-ui/bar-charts/grouped-data ,
if i give
dataSource:
{
data: stocksDataSource,
pageSize: 3,
page: 2
}
instead of
dataSource: stocksDataSource
it is not working, how can i make it work
Thanks