This is a migrated thread and some comments may be shown as answers.

Direct Printing of Report In Web Environment

3 Answers 125 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Steven
Top achievements
Rank 1
Steven asked on 16 Feb 2018, 05:54 PM

Do we are trying to come up with a solution for being able to print a Telerik report without viewing it in a HTML5 web application.  Our client is HTML5/Javascript and the backend is RESTful web services and implementation of Websockets using Microsoft SignalR.  Each client connects to the SignalR hub and therefore we have the ability to trigger client JavaScript methods from the web services or trigger hub methods from the HTML5/JavaScript clients.

At times we want to be able to print a report by clicking a button on the UI and have this pop up the bowser printer dialog without previewing the report in the HTML5 report viewer.

Looking for ideas from others that have similar functionality in their web applications.  Approaches taken and results.

Thank you,

Steve

3 Answers, 1 is accepted

Sort by
0
Rick
Telerik team
answered on 21 Feb 2018, 05:17 PM
Hello Steven,

You can open a print dialog for a Report without previewing in the ReportViewer by programmatically exporting the report to a PDF, which can be opened and printed by the browser client. This approach relies on the client browser having a compatible PDF plugin. Most browsers (except Firefox) come with the required plugin by default. We have documented the process in the following Knowledge Base, which also has a runnable sample attached.

Print a report directly at client-side without displaying it in a Viewer


Regards,
Rick
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Balaji
Top achievements
Rank 1
Veteran
answered on 24 Feb 2021, 03:13 AM

Hi Rick,

Unfortunately, i don’t have the option of writing server side code in C# or VB in my Client Side Application. I am using a pure JS/Jquery/HTML5 application with Telerik Reporting data served from API. Everything works fine and the report gets displayed in HTML5 Report Viewer and i am able to interact with it and download the report in PDF Format. My requirement is to open the Report directly as a PDF in browser and not display the Report Viewer on Client Side. Do we have an option/workaround for that with Telerik Reporting? Please advise.
Thanks,
Balaji.V

0
Eric R | Senior Technical Support Engineer
Telerik team
answered on 26 Feb 2021, 04:45 PM

Hi Balaji,

Thank you for the detailed description. If I understand correctly, you're using a Report Server with the HTML5 Report Viewer.

If this is the case, and you are looking to bypass using the Report Viewer altogether, then it is also possible to use the Report Server API and Export a report using only client-side JavaScript. Note that this will require logging, getting an Access Token and having the report id. 

Please let me know if you need any additional information. Thank you for using the Reporting Forums.

Regards,


Eric R | Senior Technical Support Engineer
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
Steven
Top achievements
Rank 1
Answers by
Rick
Telerik team
Balaji
Top achievements
Rank 1
Veteran
Eric R | Senior Technical Support Engineer
Telerik team
Share this question
or