LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

system colors override

Greetings,

 

I would like to override the conform to system colors attribute on a panel for a single control on a panel

Essentially i need to make one control the BRB (big red button).

 

However, if I try to make it red I have to uncheck conform to system colors which leads to other problems.

 

The reason that I want to do this on the source panel is because when I use the SetCtrlAttribute function to change the color, sometimes the color changes back to the standard gray.

There is no place in my code where a color is changed to gray on any other SetCtrlAttribute function call.

That leads me to believe that I am not inadvertantly changing the color back by having a bug with either an incorrect panel handle or control number.

So I assume that CVI is just changing the color back to the source color on its own.

 

Does anyone know a way of doing this?

 

Thanks

 

 

0 Kudos
Message 1 of 2
(2,798 Views)

You can override system setting for individual controls by calling SetCtrlAttribute with ATTR_DISABLE_PANEL_THEME attribute: see here. Next you can set the button color with ATTR_CMD_BUTTON_COLOR attribute.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 2 of 2
(2,775 Views)