Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

•  Prevent Acrobat to open when exporting .AI to .PDF via Scripting, possible?

Enthusiast ,
Mar 31, 2025 Mar 31, 2025

Hello -

 

I've created a Javscript that does a lot of things, including exporting this open document in .PDF format.
It works… It's just that every time Acobat is launched and it opens the freshly exported .PDF.

 

My question:
Via Javascript, is there any way to prevent Acrobat launching each time? If so, what is this function/command?

Is is via this? But if so does it have priority on the "predefined preset" of the user?

pdfExportOptions_DC.viewAfterSaving = false;

 

Thanks, have a nice day.

 

 

 

- Dimitri

 

TOPICS
Scripting
107
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Advocate , Apr 01, 2025 Apr 01, 2025

Bonjour,

Oui cette option a priorité sur le « préréglage prédéfini ».

essayez ce script:

// JavaScript Document
var doc = activeDocument;
var prestlist = app.PDFPresetsList;  alert(prestlist.join("\r"))
var positionDefaut = prompt("Position liste ",0,"EDE elleere");
var docname = doc.name.substring(0,doc.name.lastIndexOf('.'));
var pdfsaveoptions = new PDFSaveOptions();
    pdfsaveoptions.pDFPreset = prestlist[positionDefaut];
//pdfsaveoptions.pDFPreset = "";
    pdfsaveoptions.viewAfterSaving = fa
...
Translate
Adobe
Advocate ,
Apr 01, 2025 Apr 01, 2025

Bonjour,

Oui cette option a priorité sur le « préréglage prédéfini ».

essayez ce script:

// JavaScript Document
var doc = activeDocument;
var prestlist = app.PDFPresetsList;  alert(prestlist.join("\r"))
var positionDefaut = prompt("Position liste ",0,"EDE elleere");
var docname = doc.name.substring(0,doc.name.lastIndexOf('.'));
var pdfsaveoptions = new PDFSaveOptions();
    pdfsaveoptions.pDFPreset = prestlist[positionDefaut];
//pdfsaveoptions.pDFPreset = "";
    pdfsaveoptions.viewAfterSaving = false;
var targetFile = new File( "~/" + docname + ".pdf" );
    doc.saveAs(targetFile,pdfsaveoptions);
alert(targetFile);
     // doc.close(SaveOptions.DONOTSAVECHANGES);

René

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Apr 01, 2025 Apr 01, 2025
LATEST

Bonjour René -

 

Un tout grand merci…

Bonne journée

 

 

 — Dimitri

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines