Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Forums Adobe After Effects Expressions propertyIndex AND sourceText.split question

  • propertyIndex AND sourceText.split question

  • Chris Scalzo

    June 12, 2018 at 9:00 pm

    I wanted an expression on a text layer to mark #HASHTAGS and @SocialMediaNames blue. So I added the following code to the amount of color change in a bunch of Range selectors named 0, 1, 2…

    When I evalucate the value of x, it is the correct number, but this expression wouldn’t work unless I typed a number.

    I replaced
    y=text.sourceText.split(” “)[x][0];

    with
    y=text.sourceText.split(” “)[1][0];

    Also, if a gave it text that had two spaces, it through off the split from the value of the range selector.

    x=thisProperty.propertyGroup(1).propertyIndex-1;
    y=text.sourceText.split(" ")[x][0];
    if ((y == "#") || (y == "@")) 100 else 0

  • Chris Scalzo

    June 18, 2018 at 7:16 pm

    I figured out what was wrong with my property index syntax. I am still looking for a solution to my text.split problem. will reword in a new post.

Viewing 1 - 2 of 2 posts

Log in to reply.

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