Quantcast
Channel: Adobe Community : Unanswered Discussions - Illustrator
Viewing all articles
Browse latest Browse all 41949

Strange crash after exporting PDF...

$
0
0

I have a script with the following at the end:

 


var pathName = "~/Desktop/salesChartEMC.pdf";

var saveName = new File (pathName);

saveOpts = new PDFSaveOptions();

saveOpts.compatibility = PDFCompatibility.ACROBAT5;

saveOpts.generateThumbnails = true;

saveOpts.preserveEditability = true;

templateFile.saveAs(saveName, saveOpts);

templateFile.close(SaveOptions.DONOTSAVECHANGES);



alert("PDF successfully saved as "+pathName);

 

   The script keeps crashing at the templateFile.close(...) line.  If I comment out that line, the script works without crashing and I can switch back and forth between open documents and work as normally.  However, as soon as I manually close the PDF that is still open, Illustrator crashes again.  Has anyone run into this behavior before?


Viewing all articles
Browse latest Browse all 41949

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>