Hi,
My form contains several text fields with backcolor of beige. My wish is to change the beige color of the field to white after update of the field. The below sample code works well in event procedure for every field (AltINVCL is one of the fields) :
Private Sub AltINVCL_AfterUpdate()
If Not IsNull(Me.AltINVCL) Then
Me.AltINVCL.BackColor = RGB(255, 255, 255)
Else
Me.AltINVCL.BackColor = RGB(252, 230, 212)
End If
End Sub
However, this is tedious as the code needs to be modified & repeats for too many fields in VBA. Hence, I'm trying create a short cut by writing a universal code in the Public Function and run the function from the event procedure of each field.
Can some help and advise how the code in the public function to be written ?
And also, how do I run this function in desired field with backcolor of beige ?
Many thanks for any help render.
Regards
Kiang