Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Undefined Value Used In Expression; Require assistance with Start Time Stop If Else Statement Wiggle But Keeping Same Aspect Ratio.

  • Undefined Value Used In Expression; Require assistance with Start Time Stop If Else Statement Wiggle But Keeping Same Aspect Ratio.

    Posted by Kyle Balitz on August 27, 2019 at 2:35 am

    Hello, I am trying to figure out an expression of using a Start and Stop time If Else statement using Wiggle. But I need to maintain the aspect ratio of the wiggle.
    I tried to use the following syntax:

    timeToStart = 6;
    timeToStop = 16;
    if ((time > timeToStart) && (time < timeToStop))
    { w = wiggle(5,10);
    if (value[0]===0){[0, w[1]];}
    else{[w[0], w[0]*value[1]/value[0]];};
    }

    But get an error that say Undefined Value used in expression (could be out of range array subscript?) at the
    timeToStart = 6;

    Could anyone help assist me on the correct syntax for this so I do not get this error. This maybe have to do with the update in After Effects 2019.

    timeToStart = 6;
    timeToStop = 16;
    if ((time > timeToStart) && (time &lt; timeToStop))
    { w = wiggle(5,10);
    if (value[0]===0){[0, w[1]];}
    else{[w[0], w[0]*value[1]/value[0]];};
    }

    Kyle Balitz replied 6 years, 10 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    August 27, 2019 at 4:08 am

    You didn’t define what’s supposed to happen outside the start and stop zone. Try replacing the last line:

    }

    with this:

    }else value

    Dan

  • Kyle Balitz

    August 27, 2019 at 5:38 pm

    Wow Dan, that fixed it. Thanks for all the work you guys do here!

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