Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Been fighting with a simple text load expression for hours

  • Been fighting with a simple text load expression for hours

    Posted by Sergio Pol on July 20, 2015 at 11:10 pm

    Hi there, I’m trying unsuccessfully to load a simple text from a file into the source of a text box in AE. I’ve tried many formulas and path syntax with no luck.

    I’ve used the following syntax in the past and it has worked.

    I’m using AE CC2014 on windows 8.1.
    Any help would be greatly appreciated.

    myPath = "/d/SPMG/legal.txt";
    try{
    $.evalFile (myPath);
    }catch(err){
    "Not found."
    }

    Sergio Pol replied 11 years, 1 month ago 2 Members · 4 Replies
  • 4 Replies
  • Dan Ebberts

    July 20, 2015 at 11:20 pm

    What’s in the file? It has to be valid expression code.

    Dan

  • Dan Ebberts

    July 20, 2015 at 11:30 pm

    If this is a source text expression, what’s in the file needs to be something you could copy from the file and paste it in as the expression and you would get the result you expect. So any single text line enclosed in straight quotes:

    “This is a test”

    or multi-line text within triple quotes:

    “””This is a test
    with multiple
    lines”””

    should work.

    Dan

  • Sergio Pol

    July 20, 2015 at 11:31 pm

    Oh!! It’s simple paragraph text. Does it mean I can’t use expressions to load paragraph text?

  • Sergio Pol

    July 20, 2015 at 11:34 pm

    Oh gosh!! what a terrible dead end I was in. Thanks Dan.

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