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

CS6+ executeMenuCommand, pattern swatch

Community Expert ,
Mar 13, 2014 Mar 13, 2014

Copy link to clipboard

Copied

Hi all, I'm trying to create a Pattern Swatch out of the Selected Object, so I'm using

app.executeMenuCommand ('Define Pattern Menu Item');

this successfully adds the swatch to the swatches panel, but it also brings up the Pattern Options Panel and goes into "Pattern Editing Mode" where in the UI one could either click on "Cancel", "Done" or "Exit Editing Mode" buttons...

the problem is I can't exit out of the Pattern Editing Mode, has anyone discovered if there is a MenuCommand for it?

thanks

TOPICS
Scripting

Views

1.7K

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 ,
Oct 29, 2014 Oct 29, 2014

Copy link to clipboard

Copied

I'm on the same mission for Symbols. Any luck? I'm hoping there's a way to feed vars to these.

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
Community Expert ,
Oct 29, 2014 Oct 29, 2014

Copy link to clipboard

Copied

no luck, I resorted to using Actions to create the swatch...it worked.

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
Enthusiast ,
Oct 29, 2014 Oct 29, 2014

Copy link to clipboard

Copied

I've got a lot of actions to create symbols. I'm hoping to feed variables into their names. I can figure something out with renaming an existing. Terrible that Adobe won't release important info regarding these, there's gotta be a way to suppress dialogs from these things, or emulate a return key press to the dialog?

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
Guide ,
Oct 29, 2014 Oct 29, 2014

Copy link to clipboard

Copied

hey CarlosCanto,

do you use Autohotkey or anything of the like?

if so you could use that to simulate "Right mouse press" then "e" for exit pattern editing mode. and compile.

app.executeMenuCommand ('Adobe Make Pattern');

var keyfile = new File("C:/patternexit.exe");

keyfile.execute();

bit roundabout though...

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
Guide ,
Oct 29, 2014 Oct 29, 2014

Copy link to clipboard

Copied

If you do this just send {ESC}.

I did it and its working fine.

happy to post the .exe if you would like it.

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
Community Expert ,
Oct 29, 2014 Oct 29, 2014

Copy link to clipboard

Copied

Hi, that script was for distribution so in that case I had to stay within the scripting capabilities of Illustrator, many users don't want to install third party software, plus AHK is windows only, right?

...but it looks fantastic, I'll give it a try for my own use.

thanks for offering.

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
Guide ,
Oct 29, 2014 Oct 29, 2014

Copy link to clipboard

Copied

LATEST

And prob not reliable enough in that case as you have no control over a clients computer.

would need many safe guards to make sure the ESC was only pushed if illustrator window active. in case another program takes focus in that split second... etc.

as far as I know AHK is PC only, there are other alternatives but would be different scripting language.

1 of the best scripts I have written with AHK changes the default program for pdfs from illustrator to acrobat and back. modifying the registry directly.

this allows me to open pdfs straight from outlook into ether program without saving file first. as outlook has no open with dialogue.

I also have another one ( not written by me ) called FixZoomBug. this allows the ALT+mouseWheel to zoom in illustrator without the file menus activating. I could not do without this...

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