how do i write this

L

Little pete

If the date is bigger than todays date and the task is complete, I want to
change the back colour to ..........

I think it is something along these lines:

If [Task Cmp] = true
and
if the [Sep] > date()
then
ContractorName.BackColor = 16764057
Else
ContractorName.BackColor = 255


thanks for the help,
pete
 
D

Dan Artuso

Something like this maybe:

If Me.Task_Cmp And Me.Sep > Date() Then
ContractorName.BackColor = 16764057
Else
ContractorName.BackColor = 255
End If
 
L

Little pete

Got it on the end with this;

Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)

If Me.Task_Cmp Or Me.Start_Date > Date Then
Me.Contractor_Name.BackColor = vbWhite
Else
Me.Contractor_Name.BackColor = 255
End If
End Sub


thanks so much for the help everyone, fiished!!
enjoy the weekend

Dan Artuso said:
Something like this maybe:

If Me.Task_Cmp And Me.Sep > Date() Then
ContractorName.BackColor = 16764057
Else
ContractorName.BackColor = 255
End If

--
HTH
Dan Artuso, Access MVP


Little pete said:
If the date is bigger than todays date and the task is complete, I want to
change the back colour to ..........

I think it is something along these lines:

If [Task Cmp] = true
and
if the [Sep] > date()
then
ContractorName.BackColor = 16764057
Else
ContractorName.BackColor = 255


thanks for the help,
pete
 

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