We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

There is a printing issue when the horizontal width of a PDF is larger than its vertical height.

https://stackblitz.com/edit/angular-u5qyfq?file=app.component.ts

I have a PDF file with a horizontal width of 21.501CM and a vertical height of 20.300CM. The preview looks good, but the printed preview is reversed.





3 Replies

VV Visvesvar Venkatesan Syncfusion Team May 8, 2023 12:48 PM UTC

The print preview is left rotated because the horizontal length is greater than the vertical length and it behaves as a landscape PDF. Also, we recommend using the latest version(20.2.3) of PDFViewer for stability and various improvements.


We have provided the sample in the latest version and the blank page print issue is resolved in the latest version.


Sample: https://stackblitz.com/edit/angular-hkm2wi-kduust?file=src%2Fapp.component.ts,src%2Fapp.component.html,package.json


Kindly try this and let us know if you have any concerns.



TE techlandandyzhang May 9, 2023 01:16 AM UTC

As my paper's horizontal length is greater than the vertical length, I do not want the preview to rotate. Is there a way to fix this?



VV Visvesvar Venkatesan Syncfusion Team May 9, 2023 02:32 PM UTC

To make print preview not rotated for landscape documents you have to set the enablePrintRotation (#enableprintrotation) property as false.


We have attached the Code Snippet and sample for your reference below.


Code Snippet:


 <ejs-pdfviewer

      id="pdfViewer"

      [serviceUrl]="service"

      [documentPath]="document"

      [enablePrintRotation]="false"

      style="height:640px;display:block"

    ></ejs-pdfviewer>

 



Sample: V8vthe (forked) - StackBlitz


Kindly try this and let us know if you have any concerns.


Loader.
Up arrow icon