Skip to main content
Participant
January 30, 2023
Answered

Move a null with dropdown menu

  • January 30, 2023
  • 1 reply
  • 281 views

Hello, I am looking to change the values of the position of a null when i select an option from dropmenu

 

on my drop menu: 3 option of positions 

ill try this but isnt work 😞 

 

if(thisComp.layer ("Control").effect("Position")("Menu") == 1) { else dataValue(200,300) }

 

I would really appreciate your help. 🙂 

This topic has been closed for replies.
Correct answer Mylenium

Your code makes no sense. You are not defining any actual values anywhere and "dataValue" would refer to working with data-driven graphics. I think something like this is probably what you are looking for:

 

mDrop=this comp.layer("Control").effect("Position")("Menu");

 

if(mDrop==1)

{X=200;

Y=300;}

else if (mDrop==2)

{X=270;

Y=330;}

else

{X=0;

Y=0;}

 

[X,Y]

 

Mylenium 

 

 

 

 

 

1 reply

Mylenium
MyleniumCorrect answer
Legend
January 30, 2023

Your code makes no sense. You are not defining any actual values anywhere and "dataValue" would refer to working with data-driven graphics. I think something like this is probably what you are looking for:

 

mDrop=this comp.layer("Control").effect("Position")("Menu");

 

if(mDrop==1)

{X=200;

Y=300;}

else if (mDrop==2)

{X=270;

Y=330;}

else

{X=0;

Y=0;}

 

[X,Y]

 

Mylenium 

 

 

 

 

 

Participant
January 30, 2023

hahaha 😞

it works! thanks a lot!