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

Is their any way to set path in Batch of Action panel through jsx ?

Adobe Employee ,
Dec 14, 2022 Dec 14, 2022

Copy link to clipboard

Copied

Daksri_1-1671015256835.png

In Action panel, in Batch  , I want to choose location for source and destination. Is is possible through jsx ?

Your inputs would be appreciable.

 

Thanks in advance!! 

TOPICS
Scripting

Views

115

Likes

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

correct answers 1 Correct answer

Participant , Dec 20, 2022 Dec 20, 2022

It is true that ExtendScript cannot change the contents of already opened batch dialogs.

 

However, those properties are under the control of preferences, so you can change them via setStringPreference(PreferenceKey, value) if the dialog is not already open.

 

The PreferenceKey and the values that can be set are summarized in my Notion, so please check it out.
Illustrator Preferences > app.getIntegerPreference | Notion

 

var pref = app.preferences ;

// change 'Source' to 'Folder'
pref.setIntegerPrefer
...

Likes

Translate

Translate
Guide ,
Dec 14, 2022 Dec 14, 2022

Copy link to clipboard

Copied

This will not be accessable through a script. 

Likes

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
Participant ,
Dec 20, 2022 Dec 20, 2022

Copy link to clipboard

Copied

It is true that ExtendScript cannot change the contents of already opened batch dialogs.

 

However, those properties are under the control of preferences, so you can change them via setStringPreference(PreferenceKey, value) if the dialog is not already open.

 

The PreferenceKey and the values that can be set are summarized in my Notion, so please check it out.
Illustrator Preferences > app.getIntegerPreference | Notion

 

var pref = app.preferences ;

// change 'Source' to 'Folder'
pref.setIntegerPreference('plugin/BatchAction/saveMode', 0) ;

// set source path
var srcPath = '~/Desktop/some_src_folder' ;
pref.setStringPreference('plugin/BatchAction/openDir', srcPath) ;

// change 'Destination' to 'Folder'
pref.setIntegerPreference('plugin/BatchAction/saveMode', 2) ;

// set destination path
var destPath = '~/Desktop/some_dest_folder' ;
pref.setStringPreference('plugin/BatchAction/saveDir', destPath) ;

// open batch dialog
app.executeMenuCommand('Adobe Actions Batch') ;

Likes

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 Employee ,
Dec 22, 2022 Dec 22, 2022

Copy link to clipboard

Copied

LATEST

Thanks a lot @sttk3 for your help !!

Likes

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