processGenericStyle
[ Function ]
public static processGenericStyle(
controlName: string,
selector: string,
styles: Dictionary<string | string[] | null | undefined> | null
): void;
Sets multiple CSS properties for one or more HTML elements within a control.
This API is slower than the setSimpleStyle function, but it can reach dynamically changing child elements.
Parameter
Name | Type | Description |
---|---|---|
controlName | Name of the control | |
selector | CSS selector within the control | |
styles | Desired new values of the CSS property in an object. The value null (not the string "null") deletes the current value. |
Return value
Type | Description |
---|---|
void | No return value |
Available from 1.8 |
Sample - JavaScript
TcHmi.StyleProvider.processGenericStyle(
'DataGrid1',
'td[data-row="' + 5 + '"][data-column="' + 2 + '"]',
{
'background-color': 'red'
}
);