Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Setting position with a Dropdown Menu Controller

  • Setting position with a Dropdown Menu Controller

    Posted by Matthew Ingram on November 18, 2024 at 1:52 pm

    Hi there,

    I am trying to set a position on layers with a Dropdown menu controller on each layer. This code I have cobbled together is not working correctly. Option 3 puts the line where Option 1 should. And vice versa. And Option 2 is the same as Option 1. Very confused! Any help would be massively appreciated.

    Thank you!

    dropdown = effect(“Line”)(“Menu”).value;
    dropdown==1 ? value : [60,1018];
    dropdown==2 ? value : [60,947];
    dropdown==3 ? value : [60,876];

    Brie Clayton
    replied 3 weeks, 3 days ago
    3 Members · 3 Replies
  • 3 Replies
  • Dan Ebberts

    November 18, 2024 at 2:03 pm

    Try it this way:

    dropdown = effect("Line")("Menu").value;
    if (dropdown==1){
    val = [60,1018];
    }else if (dropdown==2){
    val = [60,947];
    }else{
    val = [60,876];
    }
    val
  • Matthew Ingram

    November 18, 2024 at 2:05 pm

    That works like a dream. Thank you so much, Dan. I am so grateful.

  • Brie Clayton

    November 18, 2024 at 6:53 pm

    Thank you for solving this, Dan!

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