• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Move a null with dropdown menu

Community Beginner ,
Jan 30, 2023 Jan 30, 2023

Copy link to clipboard

Copied

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. 🙂 

TOPICS
Expressions

Views

150

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Jan 30, 2023 Jan 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 

 

 

 

 

 

Votes

Translate

Translate
LEGEND ,
Jan 30, 2023 Jan 30, 2023

Copy link to clipboard

Copied

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 

 

 

 

 

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 30, 2023 Jan 30, 2023

Copy link to clipboard

Copied

LATEST

hahaha 😞

it works! thanks a lot!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines