User Tools

Site Tools


acroread:acroread
  • Here is a slick method to do it through Javascript on Linux. Create a new text file called (for instance) reload.js and put it into the directory:
   ~/.adobe/Acrobat/8.0/JavaScripts/
  • In the text file write these lines:
   reloadCurrentDoc = app.trustedFunction(
   function(currentDoc) {
   app.beginPriv();
   currentDocView=currentDoc.viewState;
   currentDocPath=currentDoc.path;
   currentDoc.closeDoc();
   currentDoc=app.openDoc(currentDocPath);
   currentDoc.viewState=currentDocView;
   app.endPriv();
   });
   
   app.addMenuItem({
   cName: "reloadCurDoc",
   cUser: "Reload",
   cParent: "File",
   cExec: "reloadCurrentDoc(event.target);",
   cEnable: "event.rc = (event.target != null);",
   nPos: 0
   });
   
   app.addToolButton({
   cName: "reloadCurDoc",
   cExec: "reloadCurrentDoc(event.target);",
   cToolText: "Reload the current document",
   cEnable: "event.rc = (event.target != null);",
   cLabel: "Reload",
   nPos: -1
   });
  • Close and open Acrobat. A toolbox item called 'Reload' appears and a corresponding menu item in the 'File' menu is added.
  • NOTE: On Ubuntu, remember to install the acrobat-plugins package from the medibuntu repository.
acroread/acroread.txt · Last modified: 2009/07/07 15:51 by viktorh