Style a Check Box
You can style a check box using the options in the Home tab. However, if you have several check boxes in Loftware Enterprise SP and you want to quickly apply the same style to multiple check boxes, you can define the style using a business rule and then apply those styles to a check box using the Style Data Ref property.
Note: Styles defined by a Style Data Ref override those configured in the Properties pane.

Styles can be defined using the following locations in the data map.
Property Type | Location in Data Map |
Example |
---|---|---|
Check Box |
/{Style Data Ref}/{Key} |
/MyStyles/color |
Wrapper |
/{Style Data Ref}/{Key} |
/MyStyles/width |

Check box styles can be defined using the following property keys and values.
Check Box Properties
Property | Description | Accepted Values | Key |
---|---|---|---|
Label Text |
Text displayed adjacent to a check box. |
String |
labelText |
Text Color |
The color of characters in the field. You can select a color or enter a hexadecimal RGB color value. Note: Color printing is possible only if supported by the device and device driver. |
#000000 to #FFFFFF (Default: F1F1F1) |
color |
Wrapper Properties
Property | Description | Key |
---|---|---|
Center X |
The distance from the middle of the field to the left edge of the label. The value is dependent on the unit of measure for the label template. |
x |
Center Y |
The distance from the middle of the field to the top of the label. The value is dependent on the unit of measure for the label template. |
y |
Width |
The distance from the left edge of the field to the right edge of the field. The value is dependent on the unit of measure for the label template. |
width |
Height |
The distance from the top edge of the field to the bottom edge of the field. The value is dependent on the unit of measure for the label template. |
height |
To style a check box using a business rule, perform the following steps:
- In Application Design
- Open the form with the check box and select the check box.
- In the Properties panel, for the Style data ref property, enter the location in the data map from which the check box obtains styling data as defined in your business rule.
Example
/MyStyles
- Add a rule to the form to run the new styling business rule with the onLoad trigger event. For more information, see Add an Action or Rule.
- Open or create an application and add the form to the application.
- View the styled check box on the application in Applications