Pdf Open Parameters
- There are a set of open parameter specify how the viewer should open the pdf. However, with the Chrome and firefox browser's default viewer, it does not work I have tried the fit which I would like the pdf fill the object. If there is no parameter support, are there any workaround?
- When opening a PDF document from a command shell, you can pass the parameters to the open command using the /A switch with the following syntax: /A 'parameter =' ' '.
May 11, 2015 open PDF File with parameters. After that a JList shows the files which fits and with a double-click on one of these entries the PDF Reader (Adobe Reader) should open this file directly on the page where the word/sentence appeares. Is there a way to start the PDF Reader with parameters like 'page=4' to jump directly to the right page?
There are a set of open parameter specify how the viewer should open the pdf . However, with the Chrome and firefox browser's default viewer , it does not work
I have tried the fit which I would like the pdf fill the object. If there is no parameter support , are there any workaround ? I tried a lot of approach but none of them work. For example, I also tried using iframe instead of object. However, the content does not resize. Thanks
user782104user7821041 Answer
Searching a solution for a problem very similar to yours, I found an interesting thread on forum.asp.net. http://forums.asp.net/t/1877403.aspx?Issue+with+embedded+pdf+object+in+chrome+browsers
At the end of the page, there is a workaround by a user working smoothly in Chrome. That seems to solve the problem.
Here it is an example:
For users fighting with http://pdfobject.com/ -> 'pdfobject.js' like me, you can change few lines of code on both minified and develop version of pdfobject.
Find:
and change with this line of code:
Hope this helps.
Not the answer you're looking for? Browse other questions tagged cssobjectpdfiframebrowser or ask your own question.
i am working on a java based tool, which should search for PDF files on selected directories and which should search for special words/sentences in this PDF files. After that a JList shows the files which fits and with a double-click on one of these entries the PDF Reader (Adobe Reader) should open this file directly on the page where the word/sentence appeares.
I tried two different things.
Runtime.exec: Logitech setpoint software windows 10.
Desktop open:
Is there a way to start the PDF Reader with parameters like 'page=4' to jump directly to the right page?
Thanks in advance
1 Answer
One of the problem you might face is not being able to directly call acrobat, if not in the Path of the computer. The solution uses two Windows commands : assoc and ftype to retrieve acrobat executable path.
Once found, you just have to build the command line as expected in acrobat's documentation :
I came with the following solution:
Beware, the code is highly optimistic for the sake of readability, several tests has to be made to ensure that the commands return the expected result. Additionally, this code has a Java6 syntax that could certainly benefit an upgrade to Java7's 'try with resources' and nio.