ReportSource for ReportServer Report

1 Answer 20 Views
General Discussions
Stephen
Top achievements
Rank 1
Stephen asked on 27 Apr 2021, 07:32 PM

Is there a report source that works with reports hosted on Telerik Report Server?

We need to develop a service that prints reports directly to a printer and want to host the report in the report server for easy maintenance.

I see report viewers have a ReportEngineConnection property, but I could not find anything like this for report source. 

Am I missing something, or has this not been implemented to print reports with the ReportProcessor?

The closest thing I see is the UriReportSource, but this requires a trdp file to be included in the project output.

Ivan Hristov
Telerik team
commented on 30 Apr 2021, 12:17 PM

Hi Stephen,

That's right - the ReportProcessor class is designed to work only with local reports and cannot access reports stored in a Report Server instance. Using the Report Server's API, you can connect to the Report Server and download the report definition to the client. I suggest also to check the Report Server API Client, which is a class designed to make your work with the Report Server assets easier.

Once fetched from the server as .trdp or .trdx, you can either use the ReportPackager or ReportSerializer to instantiate a ReportDocument, or save it locally and use the UriReportSource to render or print it with the ReportProcessor. Keep in mind that the processing of the report will be performed on the client, i.e. where the ReportProcessor works, so this application should be able to connect to the databases used in the report.

 

Stephen
Top achievements
Rank 1
commented on 30 Apr 2021, 07:30 PM

Thanks for the confirmation Ivan. Being that I want to print from a service hosted in our environment to network printers, that will be the closest to perfect solution. This does add work to the service for downloading and tracking report updates as I would not want to download the report for every stock label printed. I still think it would be sweet to have a report source for the report server since the code for printing trdp/trdx reports is quite short and simple.
Thanks again.

1 Answer, 1 is accepted

Sort by
0
Todor
Telerik team
answered on 05 May 2021, 11:33 AM

Hi Stephen,

You may log the requirement as a new feature request in our public feedback portal.

Generally, the Report Server is meant for storing the reports and rendering them. This includes also handling the database connections. Note that if you download the report definitions from the Report Server locally, you will have to handle the database connections from the new machine. The SubReports' UriReportSources may also need modification as in the Report Server they are references with the Report Category and Name and with the ReportProcessor you need to provide a path to the TRDP report definition.

To avoid the above, as an alternative, you may use the Report Server API to download rendered PDF report documents rather than report definitions. You may print the PDF files and avoid rendering the reports with the ReportProcessor.

Regards,
Todor
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
General Discussions
Asked by
Stephen
Top achievements
Rank 1
Answers by
Todor
Telerik team
Share this question
or