Skip to main content
Inspiring
November 28, 2017
Answered

Expression problems in new AE??

  • November 28, 2017
  • 3 replies
  • 3344 views

Hi guys,  I'm trying to add an expression to my type layer in After Effects and I keep getting an error for line two?

Does anyone see what could be wrong with this expression? It seems so basic.

Thanks for your help!!

HERE IT IS:

L = text.sourceText.length;

It = time – thisLayer.inPoint;

T = It*effect(“Speed”)(“Slider”);

F = Math.round( It % 1);if(F==1 |(T0)){Fl=”|”;}else{Fl=” “;}substr(0,T) + Fl

    This topic has been closed for replies.
    Correct answer Roei Tzoref

    just 2 days ago I was also looking for an expression to create a type cursor and stumbled upon the very same expression I think. it didn't work for me too.

    here's one that works and looks more elegant:

    L = text.sourceText.length;

    T = (time-inPoint)*effect("Speed")("Slider");

    F = Math.round(time % 1);

    if(F == 1 | (T<L & T>0) ){Fl = "|";}else{Fl ="";}

    substr(0,T) + Fl

    just remember to add an expression slider and name it "Speed"

    3 replies

    Mathias Moehl
    Community Expert
    Community Expert
    January 6, 2020

    Alternatively, if you don't want to write any code and happen to own iExpressions, you can use the Scroll Text Terminal expression which can add a blinking, customizable cursor and also can let your text appear letter by letter.

     

    Mathias Möhl - Developer of tools like BeatEdit and Automation Blocks for Premiere Pro and After Effects
    Roei Tzoref
    Roei TzorefCorrect answer
    Legend
    November 28, 2017

    just 2 days ago I was also looking for an expression to create a type cursor and stumbled upon the very same expression I think. it didn't work for me too.

    here's one that works and looks more elegant:

    L = text.sourceText.length;

    T = (time-inPoint)*effect("Speed")("Slider");

    F = Math.round(time % 1);

    if(F == 1 | (T<L & T>0) ){Fl = "|";}else{Fl ="";}

    substr(0,T) + Fl

    just remember to add an expression slider and name it "Speed"

    BronquesAuthor
    Inspiring
    January 21, 2018

    awesome you found it!! <3

    Mylenium
    Legend
    November 28, 2017

    The conditional statemenet is all botched. Clean it up and use the correct sway brackets and logic operators.

    Mylenium