Home General

Reporting possible bug

edited June 2001 in General
STATUS :
On an empty-just created report we place a TppLabel component. By default
it's Color property is None (clWhite).
We need to change the properties Color and Font.Color of the above component
according to a data value, so we place the following code on the
TppLabel.OnPrint Event :
" If (plData['FIELD']=0) then Begin
TppLabel.Color:=clBlack;
TppLabel.Font.Color:=clWhite;
Else Begin
TppLabel.Color:=clWhite;
TppLabel.Font.Color:=clBlack;
End; "

PROBLEM :
RB ignores the above commands or simply doesn't execute them into a final
state.

WORK-AROUND :
The above code works perfectly assuming that the Initial value of the Color
property of the TppLabel is not None (or clWhite) but another color (e.t.c.
clRed).

NOTE :
I've checked that only with a TppLabel component. Perhaps it's happening and
in other components as well.

TOOL EDITIONS :
Delphi v5 Pro sp1, RB Ent v5.56, WIN'98 SE

--
--

Best Regards

MYTSKIDIS GEORGIOS
mytskidis_g@mediconsa.ath.forthnet.gr

Comments

  • edited June 2001
    Mytskidis,

    I have no problem using your code, but you have to set the transparent
    property off.

    regards,
    Chris Ueberall;
This discussion has been closed.