Change "Clicked Colour" of Buttons

Discussion of application development using iX Developer, including but not limited to getting started, using the functions tab, properties, objects and installation.
Post Reply
manuk
Posts: 1
Joined: Tue Nov 05, 2013 5:06 am

Change "Clicked Colour" of Buttons

Post by manuk »

Hello,

I have to create a button with a defined colour when its not clicked and when its clicked.
I know that this is possible with a normal rectangle but i need to change the corner radius of every corner and this is not possible with a rectange when i use a T7A Panel.
So I would like to use a predefined button style (like "Black") because there I can change every corner radius. But here I have the problem that I can't change the colour when the button is clicked!
Is it possible to change it? Or is ther any other way to solve my problem?

Thanks,
Manuel

Josh B.
Posts: 36
Joined: Wed Oct 30, 2019 11:43 am

Re: Change "Clicked Colour" of Buttons

Post by Josh B. »

Hello,
The cog next to 'Fill' on your buttons properties will allow you to select different colors for when the button is clicked and un-clicked, by assigning the 1 and 0 value/color for the associated tag.

If you have any additional questions or require further assistance, please visit us at https://www.beijerelectronics.us/en-US/ ... ___support or give us call at 801.708.6690. Thank you.

prichlin
Posts: 13
Joined: Thu Feb 20, 2020 7:59 am

Re: Change "Clicked Colour" of Buttons

Post by prichlin »

In iX Developer 2.40 SP4, the corner radius can be modified in the Button's Properties > Appearance > Rounded corners 0,0,0,0. Each number is the pixel radius for that corner. I would recommend this as the solution to your question because you can then use the Dynamics Cog to assign Fill colors as Josh B. described.

I have seen the issue you described also. If you add a new Button and select the Style named Black (or most others, excluding Default), the Dynamics Cog next to Fill allows a Tag and fill colors to be defined. But those styles don't support Dynamics for Fill. If you click on any other component and then re-select the button, the cog is not there. The data is stored, as you can switch it back to the Default Style and the tag and colors will still be there, but they are not applied to the button with the Style.

The fill color property also cannot be scripted when the Style is selected. Button1.Fill = Color.Yellow; passes Build and validation checks but is not applied to the button.

Hope this helps!

Post Reply