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

[Solved] Kendo chart does not display remote data

1 Answer 207 Views
Charts
This is a migrated thread and some comments may be shown as answers.
maryam
Top achievements
Rank 1
maryam asked on 10 Feb 2015, 10:06 AM
Hello all,

I'm trying to bind my data (web api using entity framework 6) but still the generated chart shows no data only title and chart area.

I have something similier to this code:

<script type="text/javascript">
function createChart() {
$("#chart").kendoChart({
dataSource: {
transport: {
read: {
url: "http://localhost:*****/api/ISLFWs",
dataType: "json"
}
},
sort: {
field: "Year",
dir: "asc"
}
},
title: {
text: "Test"
},
legend: {
position: "top"
},
seriesDefaults: {
type: "column"
},
series:
[{
field: "ActualPSE",
name: "Actual PSE"
}, {
field: "TargetPSE",
name: "Target PSE"
},

{

}],
categoryAxis: {
field: "Year",
labels: {
rotation: -90
},
majorGridLines: {
visible: false
}
},
valueAxis: {
labels: {
format: "N0"
},
majorUnit: 10000,
line: {
visible: false
}
},
tooltip: {
visible: true,
format: "N0"
}
});
}

$(document).ready(createChart);
$(document).bind("kendo:skinChange", createChart);

</script>

1 Answer, 1 is accepted

Sort by
0
Genady Sergeev
Telerik team
answered on 10 Feb 2015, 05:06 PM
Hello Maryam,

The request might be failing for some reason. Can you inspect the request in your browser console or using fiddler and let us know of the status code of the request?

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