Continuous form problem

J

JT

I am having trouble with a continuous form. I have a form which shows the
expiry dates of qualifications and licences. In it I have one field which
calculates the days overdue. The expiry date is shown 14 days prior to
expiration. My problem is I have written an if statement as follows:

If [Days Overdue] > 0 Then
[Days Overdue].ForeColor = 255
Else
[Days Overdue].ForeColor = 0
End If

The problem is that it works but all the fields in the continuous form turn
red.
How can I keep a continuous form but have the code written so that it
addresses each record individually.

Many thanks in advance to anyone that may be able to help me.

JT
 
J

John Vinson

How can I keep a continuous form but have the code written so that it
addresses each record individually.

Use "Conditional Formatting" (available in A2000 and later). Select
the textboxes you want highlighted and use the Format menu option in
form design view.

John W. Vinson[MVP]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top