Sybase 2 Barcode Reader User Manual


 
CHAPTER 10 Highlighting Information in DataWindow Objects
DataWindow Designer User’s Guide 287
To control the display of the border, you define a property conditional
expression for the column’s Border property. When users run the DataWindow
object, DataWindow Designer changes the border of individual data values
based on the condition (value greater than $60,000).
Defining an
expression
The following illustration shows the Salary_Plus_Benefits column selected in
the Design view. To the right of the Design view, the Properties view shows
properties for the column, including the Border property. Next to the Border
property is a button for accessing the dialog box where you enter the
expression. The button displays an equals sign with a slash through it when no
expression has been entered, and an equals sign without a slash when it has.
In this example the Border property is set to NoBorder in the Properties view.
However, the expression defined for the property overrides that setting at
runtime.
A closer look at the
expression
The expression you enter almost always begins with If. Then you specify three
things: the condition, what happens if it is true, and what happens if it is false.
Parentheses surround the three things and commas separate them:
If( expression, true, false )
The following expression is used in the example. Because the expression is for
the Border property, the values for true and false indicate particular borders.
The value 1 means Shadow box border and the value 0 means no border:
If(salary_plus_benefits > 60000, 1, 0)