1 Reply Latest reply on Feb 18, 2013 8:19 PM by R-Bala-Krishnan

    fastening Preflight check

    shilpa25 Level 1

      Hellow Forum,

       

      I do have a slowness while running my Preflight Check - Scritpt,

      Generally, Script will call my Created Preflight profile, while I run the script.

       

      what happens is, when frequently script is applied for above two or more time, (assume, preflight panel is in checking status (preflight panel status buffering is slow), my script fails to catch error... ( i presume, this may be because of the preflight panel is still in checking status)

       

      How do i fasten my script which should not escape in catching preflight error.

       

      var myDoc = app.documents.item(0);

       

      myDoc.preflightOptions.preflightWorkingProfile = "XYZ"

       

      var myProfile = app.preflightProfiles.itemByName("XYZ");

       

                var myProcess = app.preflightProcesses.add(myDoc, myProfile);

                myProcess.waitForProcess();

                var myResults = myProcess.processResults;

          var myTest = myResults.indexOf("None");

       

      if (myTest != 0) {

      alert ("preflight error")

       

      else

       

      do Print()

       

       

      thanks & regards

      ...

        • 1. Re: fastening Preflight check
          R-Bala-Krishnan Level 2

          Hi,

          I too faced the same problem. Below are some methods you can use to overcome this problem

           

          var myResults = "process is not yet complete";

          do{

              var myProcess = app.preflightProcesses.add(myDoc, myProfile);

              myProcess.waitForProcess();

              var myResults = myProcess.processResults;

              }while (myResults.match (RegExp ('^process is not yet complete')) != null);           

           

          May this help you.

          --

          Thanks & Regards,

          Balakrishnan R