SSRS Report

Nikkiben Patel 0 Reputation points
2023-04-17T06:41:08.32+00:00

I'm working on an SSRS report and have encountered an issue with the number of pages displayed when exporting to PDF. The report generates 15 pages in the report viewer, but when I export it to PDF, it shows more than 15 pages. I'm wondering if there is a way to resolve this issue and ensure that the PDF version matches the number of pages displayed in the report viewer.

SQL Server Reporting Services
SQL Server Reporting Services
A SQL Server technology that supports the creation, management, and delivery of both traditional, paper-oriented reports and interactive, web-based reports.
2,826 questions
{count} votes

3 answers

Sort by: Most helpful
  1. AniyaTang-MSFT 12,331 Reputation points Microsoft Vendor
    2023-04-17T07:38:28.0533333+00:00

    Hi @Nikkiben Patel Did you export with extra blank pages? Or is the data displayed per page in the report viewer different from the number of rows of data displayed per page in the PDF? If there are just extra blank pages, you can refer to this link: https://learn.microsoft.com/en-us/sql/reporting-services/troubleshooting/troubleshoot-reporting-services-report-rendering-issues?view=sql-server-ver16#why-do-i-have-extra-white-space-including-blank-pages-in-my-report. If the data displayed per page of the report viewer is different from the number of data rows displayed per page of the PDF, it may be due to the difference in the report page size and PDF size that you set. If the answer is helpful, please click Accept Answer and Up-Vote for the same. If you have any questions, please feel free to let me know. Best regards, Aniya


  2. Nikkiben Patel 0 Reputation points
    2023-04-20T11:17:59.95+00:00

    The report generates 3 pages in the report viewer but when I export it to PDF, it shows 4 pages how to resolve this issue? User's image

    0 comments No comments

  3. AniyaTang-MSFT 12,331 Reputation points Microsoft Vendor
    2023-04-21T01:14:59.17+00:00

    Hi @Nikkiben Patel

    Do you have blank pages in these four pages? If so, try setting ConsumeContainerWhitespace to True.

    If there are no blank pages, then your report data exceeds the size of the physical page, resulting in pagination. When you preview in report builder, you see how the report will look like rendered by the HTML rendering extension that follows the soft paging rules. But when you export to PDF, pagination is done according to the physical page size, which follows the hard paging rule. If the physical page does not fit in, the report will need to occupy additional pages. For more details, you can refer to this link: https://learn.microsoft.com/en-us/sql/reporting-services/report-design/pagination-in-reporting-services-report-builder-and-ssrs?view=sql-server-ver16.

    Best regards,

    Aniya