1 Reply Latest reply on Dec 30, 2014 2:42 AM by Peter Spier

    Book preflight with InDesign CC Server

    JAcques TRIPOZ Level 1

      Hi,

       

      I'm trying to preflight a book using InDesign Server CC. Preflight seems to be done (takes somes seconds) but no pdf report is generated.

       

      Same code works perfectly on InDesign CC Desktop.

       

      Even tested to first write 'Coucou' to the file (just to check the path is correct and not write-protected). When I open the file, found 'Coucou'.

       

      Code:

       

      function fnPreflightBook(pLog, pIDBook, pstrPdfReportFileName)

      {

          var preflightProfile = app.preflightProfiles.firstItem();

          pLog.addMsg("Execution controle en amont <" + preflightProfile.name + ">");

         

          var f=new File("c:\\jtripoz\\jako.pdf");

          $.writeln(f.exists);

         

         

          f.open("w");

          f.write("Coucou");

          f.close();

         

          $.writeln(f.exists);

       

         

          try

          {

              // False = DO NOT open automatically the report after creation

              pIDBook.preflight(f);           

          }

          catch(ex)

          {

              pLog.addError("Erreur lors du controle en amont: " +ex.message);

              return LOG_RETURN_ERROR;               

          }

         

          pLog.addMsg("Controle en amont OK");

         

          return LOG_RETURN_OK;

      }

       

      And log :

       

      -- INFO: Mardi, Décembre 30 2014 11:14:47 - Controle en amont OK

      -- INFO: Mardi, Décembre 30 2014 11:14:47 - Export PDF C:\jtripoz\FISC-6-2014\jako.pdf(Profil: PDFACI_Jouve_colibri_UAT)

      -- INFO: Mardi, Décembre 30 2014 11:14:55 - Fermeture du fichier  /c/jtripoz/FISC-6-2014/jako.log

       

      Any idea ?

       

      TIA,

       

      J.