How do I retrieve a command call from it's index number ?
-
For example I get from the Script Log
c4d.CallCommand(14046) # SplitIs there an Index page where I can see to what method that number belongs to ?
-
Hey @Dimitris_Derm. ,
what do you mean by 'method'?
CallCommandjust invokes the CommandData plugin which has been registered under the plugin ID you passed to the call.What you can do, is resolve the numeric plugin ID integer value to a symbol. But unlike for message IDs, the docs currently do not resolve symbols to their integer values. You can do two things:
- Just search in the main symbol definition file with a text editor, i.e.,
{c4d}/resource/modules/python/libs/python311/c4d/__init__.py - Or use mxutils.SymbolTranslationCache which exists for the very purpose of resolving such integer values to symbols.
But in your case,
14046, you will draw a blank in both cases, which simply means developers never defined a public symbol for that command.

Cheers,
Ferdinand - Just search in the main symbol definition file with a text editor, i.e.,
-
@ferdinand
Thank you for replying.By "method" I meant the programmatic term which some times coincides with the term "function".
In my case I was expecting it to return the c4d.MCOMMAND_SPLIT but then remembered it's actually an ID.Isn't using the Script Log a good way to quickly and easy find all the appropriate function/class calls of objects/attributes/tools instead of manually searching the API documentation ?