3 Replies Latest reply: Oct 28, 2009 5:04 AM by joeln3 RSS

    Printing PDDoc with AFExecuteThisScript() doesn't work after an upgrade from SDK 5 to SDK8

    joeln3 Community Member

      Hello,

       

      I have made an upgrade of my plug-in which was developed with the Acrobat 5 SDK. I upgrade it to Acrobat 8 SDK and my print function doesn't work anymore.

       

      Actually I print my document using a javascript trusted function instead the function provided by the C++ library for internal reason.

       

      Here below is the code used to print my document :

      char szJavaPrint[6000];
      sprintf(szJavaPrint,
      
      "pp = this.getPrintParams(); \r\n"
      // fill pp with parameters
      "pp.interactive = pp.constants.interactionLevel.silent; \r\n"
      "\r\n"
      "this.trustedPrint(this, pp);"
      );
      
      PDDoc pdDoc = AVDocGetPDDoc(avDoc);
      
      AFExecuteThisScript(pdDoc, szJavaPrint, NULL);
      
      
      
      

      It was working with the Acrobat 5 SDK but the print seems to have no effect using the Acrobat 8 SDK. I know that there is a change between Acrobat 5 and 8 concerning the Character Set (currently I set the Character Set to "Not Set" in the Configuration Properties of the project) but I don't think that my problem comes from the Character Set.

       

      All ideas to resolve this problem are welcome.

       

      Kind regards,

      Joe