G
Guest
I have two date fields (one for parts cover, the other for labour) which
sometimes have different dates entered.
I want them to flash red if less than today's date so therefore, if one
field was last week's date and the other is next week's, how can I get one to
flash, but not the other?
The following code works to a degree, but is linked to the 'Labour' field
and therefore the parts field won't flash unless the labour field is prior to
'Date':
Private Sub Form_Current()
If Me.[um_labto] < Date Then
Me.TimerInterval = 500
Else
Me.TimerInterval = 0
For Each ctl In Me.Form
If ctl.Tag = "flash" Then
ctl.ForeColor = vbBlack
End If
Next ctl
End If
End Sub
How can I have two codes which work independently of each other on the form
timer event?
tia
sometimes have different dates entered.
I want them to flash red if less than today's date so therefore, if one
field was last week's date and the other is next week's, how can I get one to
flash, but not the other?
The following code works to a degree, but is linked to the 'Labour' field
and therefore the parts field won't flash unless the labour field is prior to
'Date':
Private Sub Form_Current()
If Me.[um_labto] < Date Then
Me.TimerInterval = 500
Else
Me.TimerInterval = 0
For Each ctl In Me.Form
If ctl.Tag = "flash" Then
ctl.ForeColor = vbBlack
End If
Next ctl
End If
End Sub
How can I have two codes which work independently of each other on the form
timer event?
tia