I want to have a variable color for, in this case, a radio button in my Twincat Hmi project. I intended to do this by binding the hexadecimal color value to an integer variable in my PLC code.
When I tried to bind this Plc variable to the hexadecimal value of the color, the button would just adopt the standard blue color in the Twincat Hmi and the color would not change for a change in the variable. Since the data type for a SolidColor is string I tried to change the type of the Plc variable from int to string, however this resulted in the same error(see figure).
How can I control the state of a solid color via my plc code?