Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions How can I turn on and off a Checkbox effect in After Effect using ExtendScript?

  • How can I turn on and off a Checkbox effect in After Effect using ExtendScript?

    Posted by Andy Troz on July 12, 2013 at 3:15 am

    I have a Checkbox effect on the first layer of the first composition in my project window. I’d like to know what the script would look like to control this Checkbox (on and off) via ExtendScript.

    This is the path to my Checkbox effect:

    app.project.item(1).layer(1).effect("Checkbox Control")("Checkbox");

    I’ve tried to turn it on using:

    app.project.item(1).layer(1).effect("Checkbox Control")("Checkbox") = true;
    app.project.item(1).layer(1).effect("Checkbox Control")("Checkbox") = 1;

    This hasn’t worked. What am I doing wrong?

    Any help would be much appreciated! Thanks!

    Andy Troz replied 13 years, 1 month ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    July 12, 2013 at 5:12 am

    Try it this way:

    app.project.item(1).layer(1).effect(“Checkbox Control”)(“Checkbox”).setValue(true);

    Dan

  • Andy Troz

    July 12, 2013 at 6:57 am

    Thank you so much Dan, that did the trick! 😀

    Best,
    Andy.

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