on 07-02-2014 1:17 PM
Dear Experts,
For quite some time we were having several issues while showing PDF Files in WebDynpro Java Components because of different versions of Adobe Readers and mainly because of browsers. Finally I have read about the option to show PDFs using IFrame.
byte[] PDFFormContent = bytes;
IWDResource resource = WDResourceFactory.createCachedResource(PDFFormContent, pdffile.getName(),WDWebResourceType.PDF);
Now this is working for me with Google Chrome, Firefox and IE without a problem. But with different pc clients of my colleagues PDF files are forced to download,when the application is called, instead of showing the PDF file in an IFrame.
Which setting is deciding to whether download the PDF or showing it embedded? Is there any way to prevent this grammatically?
Thanks and Regards,
Koray
Hi Koray,
you can do it this way:
String url = resource.getUrl(WDFileDownloadBehaviour.OPEN_INPLACE.ordinal());
then set the url on the bound IFrame property and it should be shown inplace. For Download take the ordinal of "ALLOW_SAVE".
Regards
Tobias
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If you are allowed to, you could check Adobe settings on client side.
Take a look at this:
See also the official Adobe guide Acrobat Help | Display PDF in browser | Acrobat, Reader XI
Hope this helps.
Regards,
Tobias
User | Count |
---|---|
78 | |
10 | |
7 | |
6 | |
6 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.