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

List of reference names for executeCommand();

Explorer ,
Jun 30, 2014 Jun 30, 2014

Hey!

Does anyone know if it is possible to get a list of all the reference names for the executeCommand(); function?

To be more specific; i'm talking about a list of all possible "number names", like the one highlighted in red 

app.executeCommand(2359);

2359 = Preferences

JesB

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

Advocate , Jul 09, 2014 Jul 09, 2014

Here is the post, I just put it up.

After Effects Menu Command ID’s by David Torno

Translate
Enthusiast ,
Jul 01, 2014 Jul 01, 2014
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
Enthusiast ,
Jul 01, 2014 Jul 01, 2014

Searching the forums can help a great deal, but check out this old thread:

Re: How to get codes for app.executeCommand() method?

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
Advocate ,
Jul 01, 2014 Jul 01, 2014

It might be worth creating a new Document for this. Never tried so i don't know how it works...

Something that anyone in the After Effects Scripting community can edit/ add new entry: english name / commandID / more info about how to use

Some are kind of obvious, some not at all.

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 ,
Jul 01, 2014 Jul 01, 2014

Thanks for all the replies, I appreciate it

UQg: it sounds like a good idea.

If no one has already started to create a document for this, and if I got time for it I might do some research and create one.

JesB

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 ,
Jul 05, 2014 Jul 05, 2014

By doing some research I found this list, but i haven't checked if all the codes work in newer versions of AE.

However i still think it a good idea to create a forum document so everybody can share the command codes.

Code list:

http://www.sundstedt.se/aescripts/AE_CS3_Command_IDs.pdf

JesB

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
Advocate ,
Jul 08, 2014 Jul 08, 2014

I'm already working on a CC version as well as a CC 2014 version.

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 ,
Jul 08, 2014 Jul 08, 2014

Awesome David, will you announce it at the forum when it's finished?

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
Advocate ,
Jul 08, 2014 Jul 08, 2014

Of course. I'm almost done with the CC list, just tons of typing at the moment. I'm just insane enough to tackle such a list.

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
Advocate ,
Jul 09, 2014 Jul 09, 2014

Here is the post, I just put it up.

After Effects Menu Command ID’s by David Torno

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
Advocate ,
Jul 09, 2014 Jul 09, 2014

A Database Error Occurred

Unable to connect to your database server using the provided settings.

Filename: core/EE_Config.php

Line Number: 207

Can't connect.

David, beside this issue, i'm curious how you could manage creating that list. Any tip ?

Xavier.

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
Advocate ,
Jul 09, 2014 Jul 09, 2014

Try it again, it should work right now, I just tried both links for the site and pdf. PVC has been having this random error. They are looking into it.

As far as making the list. A lot of manual typing. I spent two days screen capping the menu command dropdowns, then using text edit I typed up each command string. After which I built a script to read into the text, strip ot tabs, carriage returns, then convert the list into an array. I then looped through that array and piped each item through the app.findMenuCommandId() method to get ID. I made it a multi dimensional array with menu name and ID. I took that array and created a new document from it. The rest was manual labor of flipping the doc to rtf and then color coding the possible issue items.

As far as I know there is no way to simply just query the object to get the ID's, so I went the MacGyver right.

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
Advocate ,
Jul 09, 2014 Jul 09, 2014

Wow big work.

Glad to know that the Scripting help has its own commandId.

There are more though All the contextual ones (right-click a layer > Reveal Expression Errors.... that's the one i'm after for some time.. doesnt work)

Apparently the ones with negative id's require some particular settings, which i can't figure out.

Xavier.

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
Advocate ,
Jul 09, 2014 Jul 09, 2014

There are more though  All the contextual ones (right-click a layer > Reveal Expression Errors.... that's the one i'm after for some time.. doesnt work)

Apparently the ones with negative id's require some particular settings, which i can't figure out.

Xavier.

And this is where the community support comes into play. I would like to keep updating the document with missing/incorrect stuff. Not all menu commands will have an ID assigned (no ID means we can't use them in ExtendScript unfortunately), but the ones that do, we can add to the list. If you do find one(s) let me know. I will dabble on my own as well over time and see if I can find more. It simply boils down to adding the menu name into this code:

alert(app.findMenuCommandId("insert menu command name"));

The number that pops up is what it is, barring the duplicate name issue I mention repeatedly in the pdf though.

Thank you David, and really great work with the list

Thanks Jes, hopefully we can improve it over time.

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 Beginner ,
Jul 10, 2014 Jul 10, 2014

Hi David,

Thanks for the super useful list.

Here's a couple other commands. (tested with After Effects CC)

The most recent Undo: 16

The most recent Redo: 2035

(These don't seem to matter what the exact name of the undo/redo command are, they just always run the most recent)

Also, do you know if there is a way to get the name of the menu item if you only have the ID number?

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
Advocate ,
Jul 10, 2014 Jul 10, 2014

Here's a couple other commands. (tested with After Effects CC)

The most recent Undo: 16

The most recent Redo: 2035

(These don't seem to matter what the exact name of the undo/redo command are, they just always run the most recent)

Thanks, I was about to post a new updated pdf shortly with a ton more commands I processed today. I will add these as well. Appreciate it.


Also, do you know if there is a way to get the name of the menu item if you only have the ID number?

Sadly no. I haven't found a way to do that. It would make life easier in making this list.

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 Beginner ,
Jul 10, 2014 Jul 10, 2014

There's also a few more, but I don't know how usable they are.

The entire history stack can be accessed with ID numbers.

Basically if the history stack was something like:

Undo New Composition

Undo New Layer

Undo Change Value

-------------------------------

Redo Parent

Redo Add Shape Layer

Then the IDs would be:

Undo New Composition :      -1048577

Undo New Layer:                 -1048578

Undo Change Value             16

-------------------------------

Redo Parent                        2035

Redo Add Shape Layer        -1048582

Redo Add Camera Layer      -1048583

The stack always starts at -1048577 and then counts downward by 1 (skipping over 3 numbers when Undo changes to Redo)

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
Advocate ,
Jul 10, 2014 Jul 10, 2014

Interesting and confusing. I'll hold off on those until further investigating. I did add your other two, plus 100 new contextual menu commands. Going to upload the pdf now.

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
Advocate ,
Jul 10, 2014 Jul 10, 2014

New AECC_MenuIDs_v1_1.pdf is now live.

After Effects Menu Command ID’s by David Torno

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
Enthusiast ,
Jul 15, 2014 Jul 15, 2014

Hi David!

I got this plugin that I wrote for my own scripting that could be usefull.

You'll find 2 different plugs: CMD_AEGP & CMD_AEGP_Prompt (copy them anywhere in the plugins folder, PC only).

The first one prints the Command's ID in the info panel. It's the one I use the most. However, for some commands, AE will overwrite it really fast...

That's where the second plugin becomes usefull: it prompts an alert box with the Command ID. The problem with this one (appart the fact that it's super boring if you forgot to remove it ) is when you got it installed, you'll have to force AE to close. (it sounds pretty messy, but it's the only way I found to have it working on any version since CS5 to CC 2014)

Hope you like it!

https://dl.dropboxusercontent.com/u/52167965/CMD_AEGP.zip

Cheers,

François

http://aescripts.com/authors/f-l/francois-leroy/

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
Advocate ,
Jul 16, 2014 Jul 16, 2014

Thanks François, I will give this a try at work, as I do not have access to a PC at home.

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
Enthusiast ,
Jul 17, 2014 Jul 17, 2014

françois leroy , thanks!

Works like a charm.

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

And here is the Mac version of François's plug-in:

https://www.dropbox.com/s/bvmmmlkkhttnra0/GetCmdID_mac.zip?dl=0

(note that I've enclosed the Prompt version with parentheses, remove them if you want to use this version)

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
Enthusiast ,
Feb 28, 2016 Feb 28, 2016

David, can you please update in future the list of code with this small update?

Layer Styles -> Remove All 3744    (instead of 2072)

Thanks!

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
Enthusiast ,
Mar 15, 2016 Mar 15, 2016

Hi everyone,

seems the link was broken, so here's a new link to the Windows version:

https://www.dropbox.com/s/vwfihacjlcvo8c7/CMD_AEGP.aex?dl=0

Enjoy!

François

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