If statement that checks color of background (1 Viewer)

jordankoal

Registered User.
Local time
Today, 08:50
Joined
Sep 5, 2013
Messages
29
I have a report. In this report I have a start date and an end date. I also have a date that is going to be checked. The report checks to see if the date the user entered on a different form is between the start and end date of an individual. if it is, a txt box at the end of the line will turn red. If it isn't the box will stay default of green.

What I would like to do is not even show the lines that have a green box. I want to just show the lines that have boxes as red.

I looked into If statements but I'm not quite sure what event I should put them on, nor am I certain I have the syntax right.

I had it:
If (lblAvailability.BackColor = "#CCB13D" Then
txt1.Visible = False
and so on... making all the txt fields invisible. I would rather have them not even show up because I'm pretty sure invisible things still take up room.
End If

Any Suggestions???
 

CJ_London

Super Moderator
Staff member
Local time
Today, 13:50
Joined
Feb 19, 2013
Messages
16,555
What I would like to do is not even show the lines that have a green box. I want to just show the lines that have boxes as red.

If you don't want the line to appear at all why not modify the recordsource to your report with a criteria which uses the same formula which sets the background color of your backcolor to exclude the 'green' records
 

Users who are viewing this thread

Top Bottom