3 Replies Latest reply on Jun 2, 2009 3:24 AM by Harbs.

    close() not working in eventlistener.

    தமிழரசன் ( Thamilarasan) Level 1

      Close() function is not working but other events are working well. And my code

       

       

      #targetengine "session"
      try{
      app.eventListeners.everyItem().remove();
      }catch(e){}

       

      main();
      function main(){
      var afterPrint = app.addEventListener ("afterPrint", aDocClose, false);
      }

       

      function aDocClose(myEvent)
      {
          app.activeDocument.close();


      }