Jump to content

how a button and label color change according to the state of the variable?


Bektas

Recommended Posts

Hello ,

I have a variable in number format. I have a button and a label object.
When my variable is 1, the background color of the button and font color of the label will be green.
When my variable is 2, the background color of the button and font color of the label will be red.
How can I do these codes in Delphi and Javascript?

My Version is 1.90.0 build 1547 

TUniSpeedButton *offline1;

offline1->Down=true;   //not working

offline1->Color=(TColor)0x003FEC89;  // not working

they are very simple things but They do not work properly. Where am I making a mistake?

Thanks 

C.BEKTAS

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...