title: How do I quit InDesign and open Illustrator using InDesign scripting?
body: <p>How do I quit InDesign and open Illustrator using InDesign scripting? This is my code:</p>
  
  <pre><code>// closing the InDesign document here
  myDocument.close(SaveOptions.NO);
  
  // change the script's target to Illustrator
  #target illustrator
  
  app.documents.add(DocumentColorSpace.CMYK, width = 1024, height = 768); 
  </code></pre>
  
  <p>But here the script is not quitting InDesign, and only opening Illustrator. How can I resolve this?</p>