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

How to delete specific Artboard in illustrator using script

Participant ,
Jun 03, 2016 Jun 03, 2016

Here u can see 4 art boards on attached screenshot, but i want to delete 1,3,4 art boards

Screen Shot 2016-06-04 at 11.51.39 AM.png

i like to work with art board 2

TOPICS
Scripting
3.5K
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

Engaged , Jun 06, 2016 Jun 06, 2016

just wrap Alexander's script in a do javascript to incorporate it into your applescript workflow.

 

tell application "Adobe Illustrator"

    do javascript "    function removeArtboards ( arr ) { 

        var i = arr.length; while ( i-- ) activeDocument.artboards[ arr[i] ].remove(); 

    } 

    removeArtboards( [0,2,3] );  "

end tell

Translate
Adobe
Participant ,
Jun 03, 2016 Jun 03, 2016

As an option:

function removeArtboards ( arr ) {

    var i = arr.length; while ( i-- ) activeDocument.artboards[ arr[i] ].remove();

}

removeArtboards( [0,2,3] );

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
Participant ,
Jun 03, 2016 Jun 03, 2016

Its work good,

how to convert this in Applescript

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
Participant ,
Jun 04, 2016 Jun 04, 2016

Unfortunately I do not write on applescript.

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
Community Expert ,
Jun 04, 2016 Jun 04, 2016


karthickm50893796 schrieb:

… how to convert this in Applescript

You can use Javascript under MacOS too. It is not necessary to rewrite all Javascripts in Applescript. And the most people here „speaking“ Javascript.

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
Engaged ,
Jun 06, 2016 Jun 06, 2016

just wrap Alexander's script in a do javascript to incorporate it into your applescript workflow.

 

tell application "Adobe Illustrator"

    do javascript "    function removeArtboards ( arr ) { 

        var i = arr.length; while ( i-- ) activeDocument.artboards[ arr[i] ].remove(); 

    } 

    removeArtboards( [0,2,3] );  "

end tell

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
Explorer ,
Feb 15, 2022 Feb 15, 2022

can you update the jsx script it dosen't work for me

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
Community Expert ,
Feb 15, 2022 Feb 15, 2022

try copying the script again, I just fixed the missing indexes

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
Explorer ,
Feb 16, 2022 Feb 16, 2022
LATEST

Thank you

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