Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions scripting : creating comp

  • Dan Ebberts

    February 22, 2011 at 1:32 am

    I don’t think you can get there that way. For one thing, missingFootagePath is an attribute, and doesn’t accept any parameters.

    I think you need to create a new file object that points to your replacement file by first building the new path based on the new folder and old file name. Once you have the file object created, you should be able to just:

    myFile[0].replace(your_new_file_object);

    Something like that.

    Dan

  • Nicholas Joseph

    February 22, 2011 at 7:28 pm

    Oh I see.. That did work but its a little heavy on the memory. I have over a 100 layer. 🙂

    So there’s no other way to change the file path of a selected footage?

    Thanks for all your help Dan.

  • Nicholas Joseph

    March 2, 2011 at 9:19 pm

    hi Dan…. I was wondering if there is away to get the mouse position and feed it into a expression. I’m trying to get the X and Y position of the cursor and have a solid/Null/text layer follow the cursor around interactively.

    any tips tricks or a direction to headin would be greatly appreciated.

  • Nicholas Joseph

    July 14, 2011 at 6:02 pm

    hiya dan! 🙂
    I have a quicky question for ya…
    Do you how i might be able to select a comp through a script….and toggle select.

    i tried _MMFolder.item(each).selected = true; but it doesn’t work.

  • Dan Ebberts

    July 14, 2011 at 6:37 pm

    Are you trying to make a particular comp active in the UI?

    If so, the only way I know is to use a hack that I think Lloyd Alvarez came up with:

    theComp.workAreaDuration = 0.06;
    theComp.ramPreviewTest(“”,1,””);
    theComp.workAreaDuration = duration;

    Dan

  • Nicholas Joseph

    July 14, 2011 at 6:42 pm

    oh… I am trying to select a comp from the project window.

  • Dan Ebberts

    July 14, 2011 at 6:50 pm

    If all you want to do is to select items in the project bin, something like this works:


    {
    for (var i = 1; i <= app.project.numItems; i++){
    app.project.item(i).selected = true;
    }
    }

    If you want to actually open a comp, you have to use the hack I mentioned previously.

    Dan

  • Nicholas Joseph

    July 14, 2011 at 8:03 pm

    app.project.item(i).selected = true;
    worked perfectly!!! Thanks!!

  • Nicholas Joseph

    July 27, 2011 at 3:42 pm

    HI hI HI !! 🙂

    Does anyone know how to change the label color of a item.
    I’m referring to the LABEL in the Project window and not the layers. Im trying to change the color to green after a comp has been processed and red if it was skipped.

    thanks

    NIK

  • Dan Ebberts

    July 27, 2011 at 5:01 pm

    As far as I know, there’s no way to access label colors.

    Dan

Page 3 of 4

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy