How to Format a Row based on value of field on that row

S

Stew

Access 2003 sp2

I'd like to be able to "highlight" a row grey when the value of a particular
field on that row is zero. For instance:

Client 1 Total Billing $5,000.00
Client 2 Total Billing .00
Client 3 Total Billing $ 500.00

Where all information above would print but row 2 would be highlighted grey
to bring attention.
 
O

Ofer Cohen

On the OnFormat event on the details section, where this fields are located
in, you can write the code

If Me.FieldName= 0 Then
Me.Section(0).BackColor = 12632256 ' Gray
Else
Me.Section(0).BackColor = 16777215 ' White
End If
 
Top