Adobe Acrobat - Javascript Console
Hello,
I developed the PDF-management program "Document Manager". The program will read the PDF files of the complete structure of bookmarks. Until recently, everything ran perfectly, now I have the PDF component which I have firmly integrated into the program updated to a later version (PDF xChange Viewer). The problem is that the page numbers no longer be read correctly. The reading will speak on Javascript. From what a console is because the speech? Is there such a menu of the Acrobat Reader Console, I can find nothing in any case. Or is this to be a supplementary tool. I've certainly read through the help of Acrobat Reader times, but could I find anything unusual, so it should work properly. Any help regarding this topic is appreciated. Thank you.
Re: Adobe Acrobat - Javascript Console
In Adobe Reader, the console is normally displayed only if JavaScript errors occur. With JavaScript, but you can also activate the console and issue reports. Example:
(Console.println "Entering function: myFunction");
Re: Adobe Acrobat - Javascript Console
Hello
Where exactly is the
entered to display the console? I do not know whether I have entered at the right place, at least when I got only the message
Code:
javascript: console not defined
Re: Adobe Acrobat - Javascript Console
Hello,
See if this code can help you
Code:
"All Bookmarks are read
jcd = "function DumpBookmark (bkm, nLevel)"
jcd = jcd & "("
jcd jcd & = "var s ='';"
jcd = jcd & "for (var i = 0; i <nLevel; i + +) s + = '';"
jcd jcd & = "s + ='+-';"
jcd = jcd & "bkm.execute (this.gotoNamedDest (bkm.name)); "
jcd jcd & = "s + = bkm.name;"
jcd jcd = & "+ s + ='=====' this.pageNum;"
jcd jcd & = "s + = '\ n';"
jcd = jcd & "bkm.chd if (! = null)"
jcd = jcd & "("
jcd = jcd & "for (var i = 0; i <bkm.chd.length; i + +)"
jcd jcd & = "s + = DumpBookmark (bkm.chd [i], nLevel + 1);"
jcd jcd & = ")"
jcd = jcd & return "s";
jcd jcd & = ")"
jcd = jcd & "DumpBookmark (this.bookmarkRoot, 0);"
Re: Adobe Acrobat - Javascript Console
I am surprised that this has ever worked before. The execute method has no parameters are provided. It should read:
Code:
jsCode = jsCode & "bkm.execute ();"
Which Version of Adobe Reader or Adobe Acrobat is used for?
Re: Adobe Acrobat - Javascript Console
In the program the PDF Viewer PDF Viewer is used xChange. If I add new PDF documents The program will, then the selected documents are scanned in succession, with the entire structure of bookmarks can be read including the corresponding page numbers. Read this, the PDF document must be opened first and then is passed to the JavaScript code for this component PDF in the PDF component. The manufacturer of this PDF component then refers me every time it comes to this JavaScript code to the Acrobat Reference.
So it probably needs to run 1:1. Before, it was also very good, but then I have updated the component to a higher version and then it was broken. So I do not know if that is not more of them. The read out the bookmarks still work, but not the output the page numbers. How would under Acrobat, then probably look the code so that it jumps to the corresponding page of the bookmark?
Only bkm.execute () it does not, I have him actually say what exactly should he run.
Re: Adobe Acrobat - Javascript Console
With bkm.execute () the action is executed, the the bookmark was assigned. That is, the function does what would happen if the user clicks Adobe Reader or Adobe Acrobat with the mouse on the bookmark. If a product used by Adobe, but this discussion is a forum of Adobe meaningless.