How to set height and width of a page?

PDF-XChange Viewer SDK for Developer's
(ActiveX and Simple DLL Versions)

Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange

relapse
User
Posts: 167
Joined: Wed Jan 18, 2012 11:10 am

How to set height and width of a page?

Post by relapse »

Hi, I've found here a topic of how to GET these values. https://forum.pdf-xchange.com/ ... ght#p49629
I need to SET them. What function should I use?


Thanks.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19883
Joined: Mon Jan 12, 2009 8:07 am

Re: How to set height and width of a page?

Post by Stefan - PDF-XChange »

Hello relapse,

You have posted in the Viewer SDK section of our forums - so my reply would be based on you using the Viewer AX SDK.

You can check the InsertEmptyPages and InsertPages methods in section 2.2.2.4.1 in the Viewer AX Manual if you want to add pages to an existing document. If you are inserting empty pages - you will see hwo to select their size, and if you are inserting pages from another file - they will be inserted with their original dimensions.

If you are interested in creating a new file from scratch - then I would recommend you to take a look at our PDF Tools SDK as it is the one better suited for the purpose. Our Viewer is primarily aimed at displaying and manipulating existing PDF files - so control over creating new pages in the Viewer AX SDK is limited.

Best,
Stefan