Full Version: Background Shading
UtterAccess Discussion Forums > Microsoft® Access > Access Forms
Wood Butcher
I have a datasheet subform that i want to have the rows shaded if one of the fields is not in this month. I put this code in and what it's doing is shading everything solid black. I don't know what number is associated with which color, but I figured any number would be different, but there is no difference.

If Month(Me.SchedShip) > Month(Date) Then
Me.DatasheetAlternateBackColor = 5
Me.DatasheetBackColor = 5
Else
Me.DatasheetAlternateBackColor = 1
Me.DatasheetBackColor = 1
End If

Help?
AvgJoe
Wood Butcher,

You can use the RGB Function - something like Form.BackColor = RGB(220,13,200).


AvgJoe hat_tip.gif
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.