These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

What's the difference

pdfer
Registered: Dec 23 2010
Posts: 28

Can someone explain the difference between the Javascript used in html pages and the Javascript used in Acrobat Pro?
 
I see a great many web pages with interesting Javascripts. Why would those script be any different than what is used in Acrobat? Couldn't you just copy and pastem?
 
It always seems as if the scripts used in Acrobat are so unique and customized solely for Acrobat. Javascript is Javascript, isn't it?

Jackson C.

My Product Information:
Acrobat Pro 9.0, Macintosh
try67
Expert
Registered: Oct 30 2008
Posts: 2398
JavaScript (or actually ECMAScript) is a standard scripting language, but the same standard can't be used everywhere.
Adobe adapted JS to run in some of its applications (by adding special Objects to it), but there are huge differences between the way a browser and HTML pages work and the way Acrobat and PDF files work, for example.
What they share is the basic JS functionality, the core. You can find the core's reference here: https://developer.mozilla.org/en/JavaScript/Reference

So the bottom line is you can't copy a JS from a website and expect it to work in Acrobat as is.

More info about JS: http://en.wikipedia.org/wiki/JavaScript

- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com