Introducing ImageAbsolutePath Feature in SqlReportViewer
The recently released service pack includes a number of enhancements to the SqlReportViewer control. One of the enhancements is the addition of ImageAbsolutePath property. This property is introduced for use in scenario involving multiple server environment.
In the initial release, ImageAbsolutePath is inferred from ImageVirtualPath. In this case, the control always assume that the SqlReportViewer and SQL Reporting Service is located on the same server. However, based on customer feedback, scenarios involving multiple server location is common in enterprise application deployment.
For example, the SqlReportViewer service is hosted on ssrs-1 server while the SqlReportingService is located on web-1. The scenario requires user to set both the ImageVirtualPath and ImageAbsolutePath properties, because the inferred absolute path from a remote location will not return a correct result. A code snippet to address such scenario would be:
1 2 3 4 5 6 |
<Intersoft:SqlReportViewer x:Name="ReportViewer1" ReportProxyHandler="http://web-1/SqlReportViewerHandler.ashx" ReportName="/Northwind Reports/SalesOrderInvoice" ReportServer="http://ssrs-1/ReportServer" ImageVirtualPath="http://ssrs-1/TempImages/" ImageAbsolutePath="C:inetpubwwwrootTempImages" /> |
The above code snippet assumes that the report images will be stored to the C:inetpubwwwrootTempImages folder on the ssrs-1 server and virtually hosted on http://ssrs-1/TempImages. In this case, you need to configure ssrs-1 as the image server by creating the TempImages virtual directory.
If opening up the SQL report server as public web server is not option, simply set the ImageVirtualPath property to the web-1 server. Everything else should remain the same. In this case, you need to configure the IIS in the web-1 server by creating a virtual directory and map it to the network path in the ssrs-1 server.
I hope this post gives you insights on the new ImageAbsolutePath feature and how it can be used along with other properties to achieve advanced deployment scenarios. Any questions or feedback are welcomed.
For the complete list of enhancements and fixes in the latest ClientUI release, please visit our support page.
Regards,
Glenn Layaar