Problems with PageDisplay.DefaultLayout

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

reinierkops
User
Posts: 93
Joined: Mon Jul 07, 2008 8:41 am

Problems with PageDisplay.DefaultLayout

Post by reinierkops »

When I execute GetProperty("PageDisplay.DefaultLayout", out data); the return value is always 0 (SinglePage)
User avatar
Vasyl - PDF-XChange
Site Admin
Posts: 2449
Joined: Thu Jun 30, 2005 4:11 pm

Re: Problems with PageDisplay.DefaultLayout

Post by Vasyl - PDF-XChange »

The properties, such as:

PageDisplay.DefaultLayout
PageDisplay.DefaultZoom
PageDisplay.DefaultRotation(new)

-are initial properties only and used by the control when opening a document only.

If you want to obtain the current page layout of the open'ed document, you should:

GetDocumentProperty(docId, "Pages.Layout", dataOut, 0);

See also: "Reference\Named Items\Named Objects\Documents" section in AX help (represents a collection of all open documents).
PDF-XChange Co. LTD (Project Developer)

Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
reinierkops
User
Posts: 93
Joined: Mon Jul 07, 2008 8:41 am

Re: Problems with PageDisplay.DefaultLayout

Post by reinierkops »

The return value is always "SinglePage" even when I set it to "Facing" in the UI.
This problem has come, since the last version of the viewer SDK. Therefore, we hadn't the problem.

This is the code I execute:

mReferencedViewer.GetDocumentProperty(ActiveDocumentId, "Pages.Layout", out data, 0);

If I set the Layout to Facing: mReferencedViewer.SetDocumentProperty(ActiveDocumentId, "Pages.Layout", "Facing");
Then: mReferencedViewer.GetDocumentProperty(ActiveDocumentId, "Pages.Layout", out data, 0);

data = "Facing"

So when I set the layout via UI, I get the wrong value.
User avatar
Vasyl - PDF-XChange
Site Admin
Posts: 2449
Joined: Thu Jun 30, 2005 4:11 pm

Re: Problems with PageDisplay.DefaultLayout

Post by Vasyl - PDF-XChange »

This bug will be fixed in next build (41.4). Please wait 1-2 days.
PDF-XChange Co. LTD (Project Developer)

Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
User avatar
John - Tracker Supp
Site Admin
Posts: 5223
Joined: Tue Jun 29, 2004 10:34 am

Re: Problems with PageDisplay.DefaultLayout

Post by John - Tracker Supp »

This new build is now available

https://www.pdf-xchange.com/downloads/dev/
If posting files to this forum - you must archive the files to a ZIP, RAR or 7z file or they will not be uploaded - thank you.

Best regards
Tracker Support
http://www.tracker-software.com