Hi
If I run the angular report viewer within my main page, all is well. However if the report viewer is hosted in a <p-dialog> (or <p-overlaypanel>), the report does not render (even though data is loaded and the report can be exported). To confirm this, I even have the report visible in a <tr-viewer> on the main page behind the dialog and load them at the same time.
If the dialog is not visible when the main page opens, then the report viewer toolbar is in a column on the left, and is not operational. (see attached)
If the dialog is visible when the main page opens, then the toolbar appears at the top and functions normally. (see attached)
<tr-viewer #rptViewerBody
[containerStyle]="viewerContainerStyle"
[serviceUrl]="reportServerUrl"
[viewMode]="'INTERACTIVE'"
[scaleMode]="'SPECIFIC'"
[scale]="1.0">
</tr-viewer>
vs
<p-dialog modal="true"
appendTo="body"
header="Report"
[(visible)]="showReport"
[width]="1500"
[height]="1500">
<tr-viewer #rptViewerDialog
[containerStyle]="viewerContainerStyle"
[serviceUrl]="reportServerUrl"
[viewMode]="'INTERACTIVE'"
[scaleMode]="'SPECIFIC'"
[scale]="1.0">
</tr-viewer>
</p-dialog>
In the code, I tried both of these container styles. The result for the dialog was that relative position rendered the toolbar (top or left), but absolute position rendered nothing at all (height became 0)
this.viewerContainerStyle = {
position: 'absolute',
top: '0px',
left: '0px',
right: '0px',
bottom: '0px',
['font-family']: 'ms sans serif'
};
this.viewerContainerStyle = {
position: 'relative',
width: '1300px',
height: '1300px',
['font-family']: 'ms sans serif'
};
using @progress/telerik-angular-report-viewer": "7.19.718"
Thanks.
Print functionality doesn't work in React application.
Steps to reproduce:
1. You may use the sample project from How to use HTML5 Report Viewer in React Application article.
2. Run the project and click on Print.
The following error can be seen in the browser's console: Resource interpreted as Document but transferred with MIME type application/pdf: "https://demos.telerik.com/reporting/api/reports/clients/a7fdd020ec4/instances/3f53abd1614/documents/c3923e685e6d6ebefb3d11?response-content-disposition=inline".
Currently the Web Report Designer (WRD) can only work with reports stored on the server where the WRD Web API service is hosted.
A nice addition would be the option to select a local TRDX/TRDP file from the client file system and upload it to the server, when opening a new report for edit.
When saving such report there should be an option to download it to the client's file system as well.
With this approach the open/save operations will more closely resemble those of the standalone report designer.
Under Linux, when the font is set with Conditional Formatting some of the TextBoxes may be rendered with different that the expected Font in Docx. Other TextBoxes set with the same rule to the same font are rendered correctly.
The same report rendered in Docx under Windows produces the correct document.
In HTML5 Report Viewer it is possible to intercept a client request (e.g. the request to export a report to a particular export format) and modify it like this:
{"format":"<script>alert(1)</script>","deviceInfo":{"enableAccessibility":false,"enableSearch":true,"BasePath":"/COAT_SIT/api/reports"},"useCache":true,"baseDocumentID":"31d0a1ca0162a3f13e92bf"}
The malicious script will be executed when the error message for a missing export format is displayed in the viewer.
When the culture of the thread is the default one, the private font (e.g. "Shadow Brush") will be replaced with a substitute in the Html5 Viewer (e.g. "Verdana") as the viewer does not respect private fonts. This is normal and expected behavior. When exported to PDF the text is displayed with the correct font ("Shadow Brush") but the embedded font as claimed by the Font properties of the PDF document reader is the substitute font ("Verdana").
When the culture of the thread is changed, the private fonts are not respected and not embedded in PDF rendered document at all. The text does not appear.
When merging the ReportViewer's WPF theme dictionaries from the DLL in App.xaml, the VS2019 Designer fails due to a problem with a ZoomComboBoxStyle definition.
This causes all Telerik UI for WPF control's styles fail to load in the Visual Studio designer.
WORKAROUND
Instead of App.xaml, merge the ReportViewer's theme dictionary closer to the control.
For example in the ReportViewer's direct parent:
<Grid>
When you try to send the report through the SendMailMessage functionality but an exception is thrown, the report will disappear. If you click on Refresh and try again with fake data, the exception will be thrown but the report will remain. If you prefer to refresh it automatically, you can use the error event:
var viewer = $("#reportViewer1")
.telerik_ReportViewer({
serviceUrl: "api/reports/",
reportSource: {
report: "Report Catalog.trdp",
},
error: function (e, args) {
console.log("This event handler will be called after a page of the report is ready.");
console.log("The error message is: " + args);
viewer.refreshReport();
},
viewMode: telerikReportViewer.ViewModes.INTERACTIVE,
scaleMode: telerikReportViewer.ScaleModes.SPECIFIC,
scale: 1.0,
enableAccessibility: false,
sendEmail: { enabled: true }
}).data("telerik_ReportViewer");