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

Create temp pdf file using javascript

Explorer ,
May 05, 2016 May 05, 2016

Copy link to clipboard

Copied

I want to create a temporary pdf file of active document which will have multiple artboard  in a single pdf file,and artboards can have any combination as per user input.Like if a document have 4 artboards then range can be 1-2,1-3,1-4,2-4 etc.

var doc = app.activeDocument;

            if ( app.documents.length > 0 ) {

            var saveName = new File ( "dest" );

             saveOpts = new PDFSaveOptions();

             pdfSaveOptions.SaveMultipleArtboards = true;

            saveOpts.artboardRange="1-3";

            doc.saveAs( saveName, saveOpts );

            }

i have tried this code but no luck and also this code opening a dialog to save which i don't want,plz help thanks in advance.

TOPICS
Scripting

Views

768

Translate

Translate

Report

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
Adobe
Enthusiast ,
May 05, 2016 May 05, 2016

Copy link to clipboard

Copied

Please delete this line and try again:

pdfSaveOptions.SaveMultipleArtboards = true;

Votes

Translate

Translate

Report

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
Explorer ,
May 05, 2016 May 05, 2016

Copy link to clipboard

Copied

LATEST

Screen Shot 2016-05-06 at 11.37.45 am.png

This code is opening a dialog and also not setting the range which i have given 1-3,I do not want this dialog i want to save a temporary file or need to use save as copy it is saving the current doc as pdf which i don't want.

Votes

Translate

Translate

Report

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