Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Change text background color
fiber0pti
I want to change the background color of text in a dynamic text field if certain criteria are met. I know how to check for this criteria but how do I access the objects background color?
Find more posts tagged with
Comments
mwilliams
Hi fiber0pti,
Just use the following in the body of an if statement in the script of the dynamic text box that checks for the criteria that you'd like the value to meet.
this.getStyle().backgroundColor = "#COLOR_CODE";
Hope this helps.
fiber0pti
Has this changed? I'm getting the following error:
Caused by: org.mozilla.javascript.EcmaError: TypeError: Cannot find function getStyle in object [object Object]. (#2)
mwilliams
fiber0pti,
Where are you trying to use this at?