Izzygrace3
New member
- Local time
- Today, 15:44
- Joined
- Jul 27, 2011
- Messages
- 5
I have a form that has a combo box to that autopopulates the other fields on the table. I would like for the form to update existing data for a record, if such data exist or to add a new record if no information exist. So far, the form just makes a new entry each time you open the form as opposed to updating existing data. Any help would be greatly appriciated.
Here is the code on the after update event of the combo box:
Private Sub Unit_AfterUpdate()
Me.POC = Me.Unit.Column(1)
Me.[Phone Number] = Me.Unit.Column(2)
Me.[Orders Clerk] = Me.Unit.Column(3)
Me.[Phone Number2] = Me.Unit.Column(4)
End Sub
Here is the code on the after update event of the combo box:
Private Sub Unit_AfterUpdate()
Me.POC = Me.Unit.Column(1)
Me.[Phone Number] = Me.Unit.Column(2)
Me.[Orders Clerk] = Me.Unit.Column(3)
Me.[Phone Number2] = Me.Unit.Column(4)
End Sub