Print report without ReportViewer in ASP.NET

I am using Business Intelligent Service to send some data from MS SQL database. In ASP.NET, I create a new Reporting Viewer that takes data from BI and displays a report, then I can print it.

My question is: How to print a report without viewing reports?

early:)

+1


source to share


1 answer


I try to provide print-optimized reports as .pdf responses. This assumes the client has a .pdf reader. Since the script sounds like business oriented, this might make sense.

If the report server is directly accessible, you can access the report via the report url (something like this ...):

"http://myserver/reportserver?/MyReports/MyPrintFriendlyReport&rs:Command=Render&rc:LinkTarget=main&rs:Format=PDF"

      



I don't usually do this. To address secure access / firewall issues, I create a page to call the Reporting Services web service. The render method returns an array of bytes based on the parameters you provide ("pdf" if you specify). Then you change the headers of the content type and Response.BinaryWrite.

You should be able to Google for example code for this (I don't have one available right now).

+2


source







All Articles