Text Font Colour

Stimulsoft Reports.BLAZOR discussion
Post Reply
admin@secsol.co.uk
Posts: 34
Joined: Wed Jun 01, 2022 8:26 am

Text Font Colour

Post by admin@secsol.co.uk »

Hi, my data source for my report contains a business object with two field value : StatusMessage and StatusColour.

I can set the value for a Text field on the report to show the StatusMessage, but how can I set the font colour to show using the value of StatusColour?

Thanks
Attachments
PrtScr capture.jpg
PrtScr capture.jpg (54.62 KiB) Viewed 1140 times
Max Shamanov
Posts: 990
Joined: Tue Sep 07, 2021 10:11 am

Re: Text Font Colour

Post by Max Shamanov »

Hello,

You can try to use conditions to change the colour of the font.
Please check the following link to our documentation:
https://www.stimulsoft.com/en/documenta ... atting.htm


Thank you.
admin@secsol.co.uk
Posts: 34
Joined: Wed Jun 01, 2022 8:26 am

Re: Text Font Colour

Post by admin@secsol.co.uk »

Hi, thanks I have used the conditions to change a font colour to Red before, but in this case I want to change the font colour to the value specified in the field StatusColour from the business object.
Lech Kulikowski
Posts: 7332
Joined: Tue Mar 20, 2018 5:34 am

Re: Text Font Colour

Post by Lech Kulikowski »

Hello,

You can use the Brush Expression property.

Thank you.
Attachments
Color.mrt
(15.53 KiB) Downloaded 119 times
admin@secsol.co.uk
Posts: 34
Joined: Wed Jun 01, 2022 8:26 am

Re: Text Font Colour

Post by admin@secsol.co.uk »

Hi, Thanks for that.

When I try this on mine if I set the Text Brush to {EstimateStatistics.StatusColor} the font changes colour as expected, but if I set the Brush to {EstimateStatistics.StatusColor} the background doesn't change - any reason for that?

Also, in the Edit Expression screen the + signs on the data on the right hand side don't appear to do anything so I can't select from a data source/business object.
Attachments
PrtScr capture.jpg
PrtScr capture.jpg (48.88 KiB) Viewed 1091 times
Lech Kulikowski
Posts: 7332
Joined: Tue Mar 20, 2018 5:34 am

Re: Text Font Colour

Post by Lech Kulikowski »

Hello,

Please send us a sample report with test data that reproduces the issue for analysis.

Thank you.
Post Reply