Working with multple dynamic text fields

New Here ,
Mar 16, 2021 Mar 16, 2021

Copy link to clipboard

Copied

Hi, I am currently working on displaying some Patches in Animate.

Is there a way to controll multiple dynamic text fields with one line of code?

 

My example: 3 dynamic text fields with the instance name myText

and the according code snipped: this.myText.visible=false;

 

Unfortunaly only the first myText diapears.

Can someone help me how to let the other two texts disapear?

 

TOPICS
ActionScript , How to

Views

71

Likes

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 2 Correct answers

Adobe Community Professional , Mar 16, 2021 Mar 16, 2021
never use the same reference for different objects.  ie, change your textfield names (eg, tf1, tf2 etc)

Likes

Translate

Translate
Adobe Community Professional , Mar 16, 2021 Mar 16, 2021
Specifically, never use the same name for multiple objects within the same object. For example: NO, OF COURSE THIS WON'T WORK: myClip.text1 myClip.text1 myClip.text1 WORKS FINE: myClip1.text1 myClip2.text1 myClip3.text1

Likes

Translate

Translate
Adobe Community Professional ,
Mar 16, 2021 Mar 16, 2021

Copy link to clipboard

Copied

never use the same reference for different objects.  ie, change your textfield names (eg, tf1, tf2 etc)

Likes

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
Adobe Community Professional ,
Mar 16, 2021 Mar 16, 2021

Copy link to clipboard

Copied

LATEST

Specifically, never use the same name for multiple objects within the same object. For example:

 

NO, OF COURSE THIS WON'T WORK:

myClip.text1

myClip.text1

myClip.text1

 

WORKS FINE:

myClip1.text1

myClip2.text1

myClip3.text1

 

Likes

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