Setting zoom mode causes viewer to capture keyboardFocus

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

cew
User
Posts: 213
Joined: Tue Feb 01, 2011 8:14 am

Setting zoom mode causes viewer to capture keyboardFocus

Post by cew »

Hi,

we have a listview with several docs to choose from.
If we navigate thru the list using the keyboard, we load the currently selected document to the viewer.

Now the problem takes place:
calling

Code: Select all

axCoPDFXCview1.DoVerb(null, "ExecuteCommand", "FitPage", out dataOut, 0);
causes that the viewer to catch the keyboardfocus and we can't navigate anymore using the keyboard.

You can reproduce the problem with your modified openDocument example.
Just load a document, use "tab" to navigate to the "FitPage" button and press enter.
Now keyboard navigation has gone...

Best regards
cew
You do not have the required permissions to view the files attached to this post.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: Setting zoom mode causes viewer to capture keyboardFocus

Post by Stefan - PDF-XChange »

Hello Cew,

You are executing a UI command, and it is like if you clicked the "FitWidth" icon in the toolbar - the Viewer will get focus.
Please instead try Setting the properties for:
Objects::Documents::<Item>.Pages.Zoom
and
Objects::Documents::<Item>.Pages.ZoomMode
to the correct value of 3 and everything should be fine.

Best,
Stefan
cew
User
Posts: 213
Joined: Tue Feb 01, 2011 8:14 am

Re: Setting zoom mode causes viewer to capture keyboardFocus

Post by cew »

Best care everywhere :wink:


Regards
cew
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: Setting zoom mode causes viewer to capture keyboardFocus

Post by Stefan - PDF-XChange »

:D