Script won't run from command line execution
I've reviewed numerous solutions and none of them work. I need to execute a script in After Effects by launching through python. I've found the generic solution:
"C:/Program Files/Adobe.../AfterFx.exe" -r "Path/to/my/script/myScript.js";
If I paste this into the windows command prompt, the first part opens/runs afterfx just fine, but it doesn't run the script. If I run the script from within AFX (File:Scripts:Run Script File) it executes correctly. Every variation I've found of this generic solution doesn't work either.
Ultimately I need to run this from python:
this_aep = 'X:/path/targetAfterfxFile.aep'
os.system(this_aep )
cmd = '"C:/Program Files/Adobe.../AfterFx.exe" -r "Path/to/my/script/myScript.js";'
os.system(cmd)
Please help. I'm not a java person or a windows programmer. How can i get AFX to run the damn script automatically? It needs to run on a loaded aep file, so running it on startup won't work and I don't want to to run every time AFX opens.
