Instead of changing the field format to highlight its contents, you could set another field's Visible property to True or False to create special effects. For example, if you inserted a new field Shape field named "Shapefld" around the product name and set its Shape property to True, then you could write the script as follows:
If UnitsInStock < ReorderLevel Then
Shapefld.Visible = True
Else
Shapefld.Visible = False
End If
To highlight products that are below the reorder level by displaying a box, use an event script that looks like this:
The code builds a string containing the VBScript event handler, and then assigns it to the section's OnPrint property.
Alternatively, instead of writing the code, you can use the C1FlexReportDesigner application to type the following script code directly into the VBScript Editor of the Detail section's OnPrint property. Complete the following steps:
If UnitsInStock < ReorderLevel Then
Shapefld.Visible = True
Else
Shapefld.Visible = False
End If
The following screen capture shows a section of the report with the special effects: