× CodeTyphon MS Windows (XP, Vista, Win7, Win8.x and Win10) OS Development, discussions and problems

Question Label.Color cannot be specified.

  • Hiroshi Yokota
  • Hiroshi Yokota's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
1 week 4 days ago #17303 by Hiroshi Yokota
Label.Color cannot be specified. was created by Hiroshi Yokota
It was the same with CT7.8, but the same phenomenon is happening with his CT7.9 this time.
Sorry for the simple thing, but for some reason Label.Color cannot be specified.
For example, in the OnClick event

procedure TForm1.Button1Click(Sender: TObject);
begin
  Label1.Color := clRed;
end;

However, the Label.Color does not change.
Hmmm, this is troublesome.
I wonder why?
Am i crazy?
 

Please Log in or Create an account to join the conversation.

  • Hiroshi Yokota
  • Hiroshi Yokota's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
1 week 4 days ago #17304 by Hiroshi Yokota
Replied by Hiroshi Yokota on topic Label.Color cannot be specified.
When CT7.7 it's no problem.
The change is from CT7.8.
 

Please Log in or Create an account to join the conversation.

  • Sternas Stefanos
  • Sternas Stefanos's Avatar
  • Offline
  • Moderator
  • Moderator
  • Ex Pilot, M.Sc, Ph.D
More
1 week 3 days ago - 1 week 3 days ago #17305 by Sternas Stefanos
Replied by Sternas Stefanos on topic Label.Color cannot be specified.
Just first set TLabel property Transparent := False;

procedure TForm1.FormShow(Sender: TObject);
begin
  Label1.Transparent := False;
  Label1.Color:=clRed;
end;    
  

 

PilotLogic Architect and Core Programmer
Attachments:
Last edit: 1 week 3 days ago by Sternas Stefanos.

Please Log in or Create an account to join the conversation.

  • Hiroshi Yokota
  • Hiroshi Yokota's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
1 week 2 days ago #17306 by Hiroshi Yokota
Replied by Hiroshi Yokota on topic Label.Color cannot be specified.
Thank you, Stenas Stefanos.
I was dynamically spawning  TLabel instances on my original calendar application.
And there I changed TLabel.Color many times.
Since CT7.8, an accident occurred there, and I was honestly in trouble.
Therefore, I asked a question on this forum, but it was very helpful to receive a clear answer immediately.
I will say it again.
Thank you, Stenas Stefanos.    

Please Log in or Create an account to join the conversation.