0
How to run javascript through action
Community Beginner
,
/t5/illustrator-discussions/how-to-run-javascript-through-action/td-p/1158852
Sep 06, 2008
Sep 06, 2008
Copy link to clipboard
Copied
Is it possible to run the javascript file via illustrator action? How?
Thanks,
Prabudass
Thanks,
Prabudass
TOPICS
Scripting
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
Explore related tutorials & articles
New Here
,
/t5/illustrator-discussions/how-to-run-javascript-through-action/m-p/1158853#M238546
Sep 06, 2008
Sep 06, 2008
Copy link to clipboard
Copied
Get to the point in the action you want to run the Javascipt. Go to the Action Panel Menu and choose "Insert Menu Item...". Then navigate to your script in File>Scripts>YourScript.jsx.
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
Community Expert
,
/t5/illustrator-discussions/how-to-run-javascript-through-action/m-p/1158854#M238547
Sep 08, 2008
Sep 08, 2008
Copy link to clipboard
Copied
But be warned that this will only work during the current session. On restarting AI, the script will be lost and the Action remade.
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
New Here
,
/t5/illustrator-discussions/how-to-run-javascript-through-action/m-p/1158855#M238548
Sep 08, 2008
Sep 08, 2008
Copy link to clipboard
Copied
Oh. Well, there you go.
So, is this by design? Some kind of security thing, or is it a bug of some kind? Pretty much messes up my plans, but glad to know it... Thanks
So, is this by design? Some kind of security thing, or is it a bug of some kind? Pretty much messes up my plans, but glad to know it... Thanks
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
Community Expert
,
/t5/illustrator-discussions/how-to-run-javascript-through-action/m-p/1158856#M238549
Sep 09, 2008
Sep 09, 2008
Copy link to clipboard
Copied
Hi Karl, what were your plans, exactly?
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
New Here
,
/t5/illustrator-discussions/how-to-run-javascript-through-action/m-p/1158857#M238550
Sep 09, 2008
Sep 09, 2008
Copy link to clipboard
Copied
My ultimate goal is to force a document to only use a specific color library. To do this, I have been using the Live Color options. Of course, the only thing I can do as an action is open the Live Color (recolor artwork) tool. The artist will still have choose certain settings.
Also, there are specific layers that are locked with objects that need to conform as well. Figured I had to do that with a script. The script unlocks a layer, unlocks any objects on that layer, selects them and recolors them (With a swatch created in the script as well) then locks the object back and then locks the layer. So, the action calls the script for one part, and then the recolor artwork for the rest.
The hope (plan) was to have this setup for the artist so all they would have to do is run the action.
Also, there are specific layers that are locked with objects that need to conform as well. Figured I had to do that with a script. The script unlocks a layer, unlocks any objects on that layer, selects them and recolors them (With a swatch created in the script as well) then locks the object back and then locks the layer. So, the action calls the script for one part, and then the recolor artwork for the rest.
The hope (plan) was to have this setup for the artist so all they would have to do is run the action.
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
Community Expert
,
LATEST
/t5/illustrator-discussions/how-to-run-javascript-through-action/m-p/1158858#M238551
Sep 09, 2008
Sep 09, 2008
Copy link to clipboard
Copied
Karl, I see. And which OS, ILL version are you using?
The reason I'm asking is because I have a tool that might be of some use for you. Contact me by email for more info.
The reason I'm asking is because I have a tool that might be of some use for you. Contact me by email for more info.
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

