How to give a DBText component a other color when a value is like below zero?
Hi All,
I have some reports which show loads of data. What i would like to do is
give a DBText value a other color when it is below a value.
For example: When DBText value is lower then 0 then DBText value's color
must be red.
Is there such a property for a DBText? Or is this property available in a
newer version of Report Builder?
Because at this moment we are using Report Builder Enterprise Edition
version 7.04.
Thanks in advance,
Daniel
--- posted by geoForum on http://delphi.newswhat.com
I have some reports which show loads of data. What i would like to do is
give a DBText value a other color when it is below a value.
For example: When DBText value is lower then 0 then DBText value's color
must be red.
Is there such a property for a DBText? Or is this property available in a
newer version of Report Builder?
Because at this moment we are using Report Builder Enterprise Edition
version 7.04.
Thanks in advance,
Daniel
--- posted by geoForum on http://delphi.newswhat.com
This discussion has been closed.
Comments
There is no built-in feature to change the color of a text component based
on its value however, this can be done by checking the field value in the
DetailBand.BeforePrint event. Something like the following...
if Report.DataPipeline['MyField'] < 0 then
ppDBText1.Font.Color := clRed
else
ppDBText1.Font.Color := clBlack;
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com