Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Use text from a .txt file

  • Use text from a .txt file

    Posted by Jos Willem on August 7, 2013 at 12:32 pm

    Hi,

    I want to make 100 video’s with after effects. Each video is unique because the video is filled with personal data. To make the 100 video’s I want to use text from a .txt file. This works fine but… in the Expression I need a file path. But I don’t want to use a file path. (because I will automate the render batch)

    Is it possible to link to a .txt file (ae project and .txt file are located in the same folder) in a after effects project without define the file path?

    My Expression code I use now is:

    if ($.os.indexOf(“Mac”) != -1)
    filePath = “/Volumes/RAID1/jos/”;

    filePath += “textlist.txt”;

    $.evalFile(filePath);

    eval(thisComp.name);

    Jos Willem replied 12 years, 9 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    August 7, 2013 at 1:38 pm

    I don’t know of any way for an expression to determine the path to the project file’s folder. It’s easily accomplished with a script though, so if you’re doing batch render automation, you might want to consider going that route.

    Dan

  • Jos Willem

    August 7, 2013 at 1:53 pm

    Hi Dan,

    I want to automate the process without changing the after effects project. The plan is to create a after effects project and a .txt file. Then make a automate script (Mac OSX) to copy the after effects project and the txt file to folders and change the content of the txt file. Then I use the watch folder of after effects to render the batch.

    But now I need to change the path to the txt file. Is it possible to link the txt file without using the complete path to the file?

    Jos

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