Having trouble getting help?
Contact Support
Contact Support
How to change the default width and height
6 Dec 20241 minute to read
To change the default width and height of the Syncfusion® PDF Viewer, modify the Width
and Height
properties of the PDFViewer control.
<div>
<div style="width:100%;height:600px">
@Html.EJS().PdfViewer("pdfviewer").ServiceUrl(VirtualPathUtility.ToAbsolute("~/Home/")).DocumentPath("https://cdn.syncfusion.com/content/pdf/pdf-succinctly.pdf").Height("1000px").Width("80%").Render()
</div>
</div>
In this example, the Width property is set to 80%
, and the Height property is set to 1000px
. Change these values to any desired size in pixels or percentages.