OLE embedded Viewer is not showing toolbars

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

1shadow
User
Posts: 13
Joined: Tue May 21, 2013 7:19 am

OLE embedded Viewer is not showing toolbars

Post by 1shadow »

Hi,
this is my problem and any help would be greatly appreciated :)

I'm evaluating the use of PDF-Viewer Pro SDK for our business solution - to be specific embedding a fully featured PDF viewer in Eclipse RCP. I'm currently having problem displaying any toolbars with direct referencing of the ClientSite (not referencing default viewer ). Also, there is very limited functionality within the embedded OLE Frame
Here's a simple code snippet:

Code: Select all

this.clientSite = new OleClientSite(this.aFrame, SWT.NONE, "PDFXCviewAx.CoPDFXCview");
this.clientSite.doVerb(OLE.OLEIVERB_INPLACEACTIVATE);
auto.invoke(0x5, new Variant[] { new Variant(tempFile.getAbsolutePath()) });
thx
You do not have the required permissions to view the files attached to this post.
Last edited by 1shadow on Tue May 21, 2013 12:19 pm, edited 1 time in total.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: OLE embedded Viewer is not showing toolbars

Post by Stefan - PDF-XChange »

Hello 1shadow,

I've moved your topic to the correct developer forums (you posted it originally in the end user ones).

To upload images - please zip/rar/7z them first and you can then upload the archive without any issues.

Best,
Stefan
1shadow
User
Posts: 13
Joined: Tue May 21, 2013 7:19 am

Re: OLE embedded Viewer is not showing toolbars

Post by 1shadow »

Thanks for the quick reply. I added the screenshot of the problem.
User avatar
Vasyl - PDF-XChange
Site Admin
Posts: 2448
Joined: Thu Jun 30, 2005 4:11 pm

Re: OLE embedded Viewer is not showing toolbars

Post by Vasyl - PDF-XChange »

Hi, 1shadow.

You have used our ActiveX control with progid "PDFXCviewAx.CoPDFXCview". By default this control doesn't show the any toobars or menu bar, it shows only the pages-view with scrollbars as in screenshot from you. To show cmdbars:

Code: Select all

auto.invoke(0x1, new Variant[] { new Variant(""), new Variant("ExecuteCommand"), new Variant("ToggleAllBars"), 0, 0 });
// == IPDFXCview::DoVerb("", "ExecuteCommand", VARIANT("ToggleAllBars"), 0, 0);
I'm not sure about order of parameters for 'invoke' function - it can be reversed..

HTH
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.
1shadow
User
Posts: 13
Joined: Tue May 21, 2013 7:19 am

Re: OLE embedded Viewer is not showing toolbars

Post by 1shadow »

Thanks, it worked, although not as expected - it showed only one toolbar.
But I managed to display all the toolbars with setProperty.

Code: Select all

automation.invoke(0x16, new Variant[] { new Variant("View.Bars[\"File\"].Visible"), new Variant(1) });
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: OLE embedded Viewer is not showing toolbars

Post by Stefan - PDF-XChange »

Hi 1shadow,

Glad to hear that you managed to make it work - and certainly you can toggle the visibility of individual toolbars as well.

Regards,
Stefan