We are facing an issue while generating the PDF file in our VB .Net code using iTextSharp (version 5.0.2.0). We need to have different pages with different width in our PDF document having, first and second page with standard width and height while, starting from third page, the page width should be increased by 20% more comparing with first and second page. When we set the page’s width to be increased, the contents on the page got cut off/slides to the right side of the page. Is there any way to set the different pages width and get the contents centrally aligned? The code we have used to get the page width increased is:
PdfDocument.NewPage()
Dim pgSize As New iTextSharp.text.Rectangle(700, 792)
PdfDocument.SetPageSize(pgSize)
Please suggest any solution on this.