SetAttributeToThemeValue

function SetAttributeToThemeValue(control: TcHmi.Controls.System.baseTcHmiControl, propertyName: string): void

The function SetAttributeToThemeValue sets an attribute of a control to the value of the active theme. In the case of a change of theme, the value of the attribute is changed in accordance with the new active theme. Refer also to the description page for the corresponding API function.

Parameter

Name

Type

Description

control

TcHmi.Controls.System.baseTcHmiControl

The control for which the attribute is to be set.

propertyName

string

Name of the attribute that is to be set to the value of the active theme.

Return value

Type

Description

void

No return value.

NuGet package: Beckhoff.TwinCAT.HMI.Functions

SetAttributeToThemeValue 1:

NuGet packages are available from version 1.12.

SetAttributeToThemeValue 2:

Available from version 1.10