Hello,
I recently set up a report in ASP.NET MVC. The report viewer is created using the HTML helper in the razor view. Everything works except for the date pickers for some ReportParameters and the dropdown menu for exporting the report.
When I hover/click on either of those controls I get the following JS error: elem.getClientRects is not a function
I suspect I am missing a JS file.
The JS files included in the page are (in order of inclusion):
- telerikReportViewer.kendo-11.0.17.222.min.js
- telerikReportViewer-11.0.17.222.min.js
The CSS files included are (in order of inclusion):
- kendo.common.min.css
- kendo.blueopal.min.css
The ENTIRE view for the report viewer looks like:
@model Telerik.Reporting.TypeReportSource
@
using
Telerik.Reporting
@
using
Telerik.ReportViewer.Mvc
@section style {
@Styles.Render(
"~/Content/css/KendoReporting"
)
<style>
#reportViewer1 {
position: relative;
margin-left:auto;
margin-right:auto;
width: 900px;
height: 900px;
font-family: Verdana, Arial;
}
</style>
}
@section scripts {
@Scripts.Render(
"~/bundles/KendoReporting"
)
}
@(Html.TelerikReporting().ReportViewer()
.Id(
"reportViewer1"
)
.ServiceUrl(Url.Content(
"~/api/reports"
))
.ReportSource(Model)
.ViewMode(ViewMode.Interactive)
.ScaleMode(ScaleMode.Specific)
.Scale(1.0)
.PersistSession(
false
)
.PrintMode(PrintMode.AutoSelect)
)
And finally the bundles used look like:
//Telerik Reporting Bundles
bundles.Add(
new
ScriptBundle(
"~/bundles/KendoReporting"
).Include(
"~/Scripts/Local/ReportViewer/telerikReportViewer-11.0.17.222.min.js"
,
"~/Scripts/Local/ReportViewer/telerikReportViewer.kendo-11.0.17.222.min.js"
));
bundles.Add(
new
StyleBundle(
"~/Content/css/KendoReporting"
).Include(
"~/Content/kendo.common.min.css"
,
"~/Content/kendo.blueopal.min.css"
));
In the main view layout, the JS files are loaded FIRST in the head, then the CSS files.
Thank you!