Search results

Adding data visualization scripts

To render the report with data visualization components such as chart, gauge and map items, must add scripts of the visualization element. The following table shows the script reference that need to be added in Report Viewer page for data visualization elements.

Visualization Item Script File
Chart ej.chart.min.js
Gauge ej.lineargauge.min.js, ej.circulargauge.min.js
Map ej.map.min.js

To render the chart report item, add chart control script ej.chart.min.js before the ej.report-viewer.min.js reference in Default.aspx page as in following code sample.

<link href="Content/reports/material/ej.reports.all.min.css" rel="stylesheet" />
<script src="https://code.jquery.com/jquery-1.10.2.min.js" type="text/javascript"></script>
<script src="Scripts/reports/common/ej.reporting.common.min.js"></script>
<script src="Scripts/reports/common/ej.reporting.widgets.min.js"></script>

<!--Used to render the chart item. Add this script, only if your report contains the chart report item.-->
<script src="Scripts/reports/data-visualization/ej.chart.min.js"></script>

<!-- Report Viewer component script-->
<script src="Scripts/reports/ej.report-viewer.min.js"></script>

The following code can be used to render the chart, gauge and map report items in Report Viewer.

<link href="Content/reports/material/ej.reports.all.min.css" rel="stylesheet" />
<script src="https://code.jquery.com/jquery-1.10.2.min.js" type="text/javascript"></script>
<script src="Scripts/reports/common/ej.reporting.common.min.js"></script>
<script src="Scripts/reports/common/ej.reporting.widgets.min.js"></script>

<!--Used to render the chart item. Add this script, only if your report contains the chart report item.-->
<script src="Scripts/reports/data-visualization/ej.chart.min.js"></script>

<!--Used to render the gauge item. Add this script, only if your report contains the gauge report item. -->
<script src="Scripts/reports/data-visualization/ej.circulargauge.min.js"></script>
<script src="Scripts/reports/data-visualization/ej.lineargauge.min.js"></script>

<!--Used to render the map item. Add this script, only if your report contains the map report item.-->
<script src="Scripts/reports/data-visualization/ej.map.min.js"></script>

<!-- Report Viewer component script-->
<script src="Scripts/reports/ej.report-viewer.min.js"></script>