Q: I upgraded to the latest version of jPDFNotes v2016R1. I am loading a PDF that has JavaScript form field validation, but I received this error:

com.qoppa.pdf.PDFException: Error loading PDF org.mozilla.javascript.Context.initSafeStandardObjects(Lorg/mozilla/javascript/ScriptableObject;Z)Lorg/mozilla/javascript/ScriptableObject;
java.lang.NoSuchMethodError: org.mozilla.javascript.Context.initSafeStandardObjects(Lorg/mozilla/javascript/ScriptableObject;Z)Lorg/mozilla/javascript/ScriptableObject;

A: Starting in version v2016R1, Qoppa’s PDF components started using Rhino version 1.7.7.1 instead of version 1.4. We upgraded to the latest version of Rhino in order to allow JavaScript sand-boxed mode that only initializes “safe” java objects (“leaving out those that offer access directly to Java classes”).

To correct the problem, remove the old js-14.jar from your classpath and add the new rhino.jar.