Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Text Value color based on Condition in Text object

Hi All,

Is there any way to change the text object value Color based on some condition?.

I have a text object below,

='       A Class:' & count({DIM_Type = {'A'} >}distinct Class_Key) &

'         B Class:' & count({ DIM_STYPE = {'S'} >}distinct Class_Key)

And based on the below condition text colour has to change,

=if(Count(Remark)>=1 then Text object value should change to "Red" colour

Thanks,

Selva

3 Replies
Anonymous
Not applicable
Author

Hi Selva,

Under the Text Object Properties > Font tab> if you click the color icon you can use a calculated color condition to set the text color to an expression.

For example:

=If(5+5=10, lightred(), black())

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

     yes you can do this.

     Go to properties of textbox.

     Click on the color

     You will find the option "Calculated" Select that and paste your expression. like

              if(count(Remark)>=1, Red())

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Not applicable
Author

Thanks Kaushik & Johannes.. It's Perfect..