Updating a field in parent form from sub-form

miacino

Registered User.
Local time
Today, 08:14
Joined
Jun 5, 2007
Messages
106
I am trying to update the background color of a field in my sub-form's parent form.
-------------
Private Sub Combo23_AfterUpdate()

If Me![Status] = "Pending: Waiting for Authorization" Then
Me.Parent.OverallStatus.BackColor = QBColor(6)
End If

End Sub
----------------

It works by updating the field, however, it is not just updating that particular parent field - it is updating the color on ALL records for that field. How do I make it exclusive to just changing the color of the parent field of THAT record?

Also, and less important - is there a color coding better for bright yellow?
 
Hi. You'll need to add the same code in the main form's Current event and add an Else branch to reverse the color if the condition is False.
 
Ahhhhh... thank you DB guy!
 

Users who are viewing this thread

Back
Top Bottom