In Reporting Services, increase background image quality above 96 dpi

I would like to use a background image, and when I put it in Reporting Services 2008 R2, the dpi will be reduced to 96 dpi. (instead of 300)

This is too small to be read by the user, I'm afraid.

When I go to the Internet, I find this result:

http://social.technet.microsoft.com/Forums/en-US/sqlreportingservices/thread/48de91f9-1844-40c1-9614-5ead0b4b69a5#P1Q14

Question 14 : How to improve the quality of a PDF report exported to Reporting Services 2005?

Answer . Reporting Services 2005's PDF renderer resizes all images that they display in 96 DPI, regardless of what DPI image you pass to the renderer. This means that an image with a resolution of 300 DPI or even 600 DPI will be in PDF format, as if it were only 96 DPI. In other words, your high DPI image may appear larger than expected.
Despite the size of the images, as if they were 96 DPI, PDF rendering seems to provide higher quality DPI images with higher quality than 96 DPI. Even if the size is not true, the image is actually higher quality. A necessary workaround is image size for the correct number of inches based on 96 DPI calculations. Then use Bitmap.SetResolution to set the images to at least 300 DPI. This can provide a higher quality image corresponding to the number of pixels that fit correctly in the report.

But I don’t know how to use this Bitmap.SetResolution, I use the classic web-based report viewing control and I really need a fully functional pdf export.

PS: Maybe this problem was solved in Reporting Services 2012. Does anyone have any information?

Hi

+6
source share
3 answers

I found a webpage that explains how to export PDF with good resolution. http://codeproject.com/Articles/95750/High-fidelity-printing-through-the-SSRS-Report-Vie

The key is to initialize the deviceInfo string with xml code

var sb = new System.Text.StringBuilder(1024); var xr = System.Xml.XmlWriter.Create(sb); xr.WriteStartElement("DeviceInfo"); xr.WriteElementString("DpiX", "296"); xr.WriteElementString("DpiY", "296"); xr.Close(); deviceInfo = sb.ToString(); rsExec.SetExecutionParameters(parameters, "fr-fr"); results = rsExec.Render(format, deviceInfo, out extension, out encoding, out mimeType, out warnings, out streamIDs); 

In this case, this solution works. I can create a PDF file with good dpi resolution, but the print button with activex does not work (this should not be a problem) and the export button. I have to add a download button to print. what's the private solution imho

+4
source

I ran into the same problem and managed to find a solution here:

SQL Server Reporting Services and Overlay Data Services

You can download a sample project to see the result.

Good luck.

0
source

If you use the WebAPI interface for Reporting Services, I have found that this method works:

For best PDF rendering of images, pass device information like this: http://serverName/ReportServer?/pathtoReport/ReportName&InvoiceIdOrOtherParameter=24013&rs:Command=Render&rs:Format=PDF&rs:DeviceInfo=<DpiX>300<%2FDpiX><DpiY>300<%2FDpiY>

0
source

All Articles