Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Array variable attached to slider not working right

  • Array variable attached to slider not working right

    Posted by Stephen Schleicher on April 26, 2018 at 1:48 am

    So I’m trying to use a variable attached to a slider to control which line from a .json file the data is being read from.

    This works:
    eval(“var temp=”+footage(“miaa.json”).sourceText);
    X=0
    temp[X].R1

    This does not:
    eval(“var temp=”+footage(“miaa.json”).sourceText);
    X=thisComp.layer(“line”).effect(“Slider Control”)(“Slider”);
    temp[X].R1

    Can anyone help me out here?

    Dan Ebberts replied 8 years, 4 months ago 2 Members · 1 Reply
  • 1 Reply
  • Dan Ebberts

    April 26, 2018 at 6:16 am

    Try changing this line:

    X=thisComp.layer(“line”).effect(“Slider Control”)(“Slider”);

    to this:

    X=thisComp.layer(“line”).effect(“Slider Control”)(“Slider”).value;

    Dan

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