I have a data entry form with many fields. I would like to have the fields with data colored and the empty ones white.
I created the following code for Form_Current()
If [Field1] <> "" Then
[Field1].BackColor = RGB(255, 255, 204)
Else
[Field1].BackColor = RGB(255, 255, 255)
End If
If [Field2] <> "" Then
[Field2].BackColor = RGB(255, 255, 204)
Else
[Field2].BackColor = RGB(255, 255, 255)
End If
I repeated the above for each field on the form.
I have 2 questions
1. Is there an easier way to accomplish this without repeating this for each field.
2. After data is entered in a field and we tab to the next field, is there an easy way to have the previous field change color besides repeating the code on a lost focus or similar.
Thanks,