I have a class library where all my reports are. One of my reports needs to be displayed and exported to PDF in landscape mode instead of portrait. In my web application which is a MVC Core application using a target framework of 4.6.1 displays the report fine in the report viewer.
Do I need to do something with the jQuery to tell the report to print according to the class report settings?
Do I need to set something else in the report definition itself that will take care of it?
See the screenshot for the report properties settings.
Here is the jQuery I am using to render the report viewer:
<
script
>
function setReportSource(report) {
var viewer =
$("#reportViewer1")
.data("telerik_ReportViewer");
viewer
.reportSource({
report: report
});
}
$(document).ready(function () {
$("#reportViewer1")
.telerik_ReportViewer({
serviceUrl: "../api/reports/",
reportSource: {
report: "MBIntranet.Reporting.DownTime.ReasonCodeReport, MBIntranet.Reporting",
parameters: {}
},
viewMode: telerikReportViewer.ViewModes.INTERACTIVE,
scaleMode: telerikReportViewer.ScaleModes.SPECIFIC,
scale: 1.0,
});
$("#reports")
.on(
"change",
function () {
setReportSource($(this).val());
});
});
</
script
>