Link to home
Start Free TrialLog in
Avatar of Prabhu Thirumalaisamy
Prabhu Thirumalaisamy

asked on

Print SSRS Report

How can invoke SSRS print window from VBA code or how can i print SSRS report by using URL parameters? i have VBA application, which has form with print report button, on click of print i need to show print window to select printer and print the report.
Avatar of lcohan
lcohan
Flag of Canada image

You would need to create a "helper" assembly exposed to COM. This assembly would be able to print the report programmatically. In Winforms applications SSRS report is meant to be printed from the reportviewer control, but there's a number of third-party components that allow direct printing, plus Microsoft's own walkthrough how to implement it (the walkthrough is about local report, but most likely it can be a remote one as well - subject to some experimentation; or you could just grab SSRS file and use it as local report). You VBA code would have to call this assembly by CreateObject, and assembly would print the report.
Hi Prabhu,

The report, is it based on the yesterday's business data or it has to run in real-time mode and print via VBA?
If yesterday's business data then one simple method is to create a subscription with the destination of Windows File Share.  Of course it has several options that might suit your needs.

Just a thought.
This question needs an answer!
Become an EE member today
7 DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform.
View membership options
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.