Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.

Renaming controls

Avatar

Former Community Member
Hi



Can anyone please advise me what the difference is between this..



I have a Static Text field called StaticText5 which I can change the colour with the following. StaticText5.font.fill.color.value = "0,0,0" which works fine.



When I rename the control to say SearchText and give the code the new name it no longer works.



SearchText.font.fill.color.value = "192,192,192"



Thanks in advance



Mike
2 Replies

Avatar

Former Community Member
There's no difference that I see other than the color you are specifying. Are you sure the first one works? Neither should.



Chris

Adobe Enteprise Developer Support

Avatar

Former Community Member
Ok



Well the first method does work.



Is there a preferred method in changing the colors of controls at runtime?



Thanks



Mike