Questions tagged [extendscript]

ExtendScript is one of the scripting languages available for implementing custom functionality for Adobe products like Photoshop, Illustrator, etc. ExtendScript is based on, and has been kept locked specifically to, ECMAScript 3 (released in 1999).

ExtendScript, or JSX (not to be confused with React's JSX markup) is a scripting language based on ECMAScript 3 (1999) used for scripting custom functionality in Adobe products like Photoshop, Illustrator, etc.

It is syntactically equivalent to JavaScript 1.5, with the same standard library, as well as a custom API for interacting with Adobe product applications and documents.

ExtendScript does not support any language features or standard library functions that were introduced after ECMAScript 3.

930 questions
-1
votes
1 answer

Get possible hyphenation for the selected word

I am new to scripting in Adobe Software. I would like to write a script, which shows me, where I can hyphenate a word. I wonder, if there is any way to get this information from the build in spellchecker. It should also take the current language…
Afterlame
  • 1,188
  • 2
  • 13
  • 32
-1
votes
1 answer

Drawing a Line in InDesign CS5.5 using ExtendScript

I would like to know how to draw a line on InDesign using Extended Script something like pseudo code for(x = 0; x < 5; x++){ drawLine(The X Value to startLine, The Y-Value to startLine, Length, Color); } Any help would be greatly…
user1275351
  • 41
  • 1
  • 1
  • 6
-1
votes
1 answer

Return postscript font name quickly

Using CS2, is there not a quicker way to get the postscript name of a font than looping over all installed fonts and comparing names? function gimmePostScriptFontName(f) { numOfFonts = app.fonts.length; for (var i = 0, numOfFonts; i <…
Ghoul Fool
  • 6,249
  • 10
  • 67
  • 125
-1
votes
1 answer

Adobe ESTK Cancel button that really cancels

Is it really that hard? Is my google-fu obtuse? How the heck do I make a cancel button that CANCELS the execution of the rest of the script? My script is dumb. I'm not a good coder, I know that, but here's what I've got: I'm automating INDD CScloud.…
JawzX
  • 293
  • 1
  • 2
  • 15
-1
votes
1 answer

Java - Illegal use of reserved word 'import'

I'm trying to import the package java.util.regex.*; and keep hitting an error in line 1 of my code. import java.util.regex.*; Returns error: Illegal use of reserved word 'import' Any idea what is going on here? I'm writing my code in Adobe…
Dig_Dig_Dig
  • 125
  • 13
-1
votes
1 answer

extendscript, get folder name

I have been learning and using Extendscript with After Effects CS6 (normally use maxscript and python) to create a dockable UI for After Effects. I have managed to do this, but need to restructure the code to search within folders in a root folder…
EMJAY
  • 5
  • 7
-1
votes
1 answer

JSX/Photoshop - Good reference material with examples?

I really appreciate community efforts for sharing knowledge via reference documentes but I'd like to know if there exist really good material for JSX scripting learning. Adobe has very well organized reference docs but the examples are poor. XTools…
Sergio
  • 608
  • 12
  • 35
-1
votes
2 answers

Using Regex to Split String

So I have a string like this (the hashtags are delimiters) A1###B2###C3###12345.jpg I was wondering how would I access A1, B2 and C3 STRING1###STRING2###STRING3###STRING4.jpg SOME###THING###HERE###MEH.jpg EXTRACT###THIS###PLEASE###pah.jpg In one…
pee2pee
  • 3,619
  • 7
  • 52
  • 133
-2
votes
2 answers

Counting pages in Adobe InDesign (by script)

In Adobe InDesign, a magazine can have 64 pages or, sometimes, 120 pages, in general, a varying number of pages. It would be great if the script could indicate the total number of pages in the PDF document. For example, if the document has 120…
Rayan
  • 1
-2
votes
2 answers

Visual Studio Code - coding beginner

everyone. I am a graphic designer, and thought I would start to learn coding to write scripts for Adobe Illustrator in ExtendScript/JavaScript. I started some beginner tutorials and have been making progress. A response to a question I had posted on…
Radius
  • 13
  • 1
-2
votes
1 answer

Illustrator to Photoshop scrript

I have found an illustrator script which i want to use in photoshop as both softwares are made by same company there wont be any problems given some minor changes. I want to convert the object method in illustrator to selection method in photoshop…
-2
votes
3 answers

Javascript - Split string by white space and join two words by "|"

I think this is very easy but I can't figure it out. var str = "How are you doing today?"; var res = str.split(/\s+/g); And the result would be: How,are,you,doing,today?. When user add character "|" between two words like this var str = "How are…
Aleksandar
  • 11
  • 5
-2
votes
1 answer

Am I missing something for Javascript?

I have a small issue. I can't seem to use object.create(), object.setprototypeof() or any function that is in this list: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object I'm getting a "function is undefined"…
-2
votes
1 answer

Looking for a photoshop script to add text to image and resize to fit

I have a psd file with two text layers. I would like to add a quote in the first text layer and a name in the second. The data is coming from a csv. The quotes can vary in length. The font size for the "quote" text layer therefor needs to be set to…
-3
votes
1 answer

store objects in associative array

How do I store ExtendScript objects in associative array? var assArray = {}; for (i=1; i<=app.project.items.length; i++) { //alert(app.project.item(i).name); one of them is "_vegs" assArray[app.project.item(i).name] =…
sanjihan
  • 5,592
  • 11
  • 54
  • 119
1 2 3
61
62