Hi, I need help with another combo box.
my database has information about car manufacturerss and their id numbers:
ie
honda, ID 50-1
honda, ID 50-2
honda, ID 50-3
toyota, ID 99-1
toyota, ID 99-2
I have a form that displays each of these records. There is also a combo box that the user can open to find a record and update the information in the form based on the selection made in the combo box. This combo box, when opened, displays the car manufacturer and ID # in exactly the same fashion as above.
here is the code i am using.....
Private Sub Form_Current()
'Displays Car Manufacturer in combo box
Combo36 = CarManufacturer
Sub Combo36_AfterUpdate()
' Find the record that matches the control.
Me.RecordsetClone.FindFirst "[CarManufacturer] = '" & Me! [Combo36] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark
End Sub
Here's my problem:
no matter which selection I make in the combo box, be it honda ID50-1, honda ID50-2, honda ID50-3, the form is updated based on the honda record with the FIRST id # (honda 50-1).
Same thing happens with any toyota record.
So if I open the combo box and select honda ID50-3, the form will show the information for Honda ID50-1. Why???
How do I fix this?
Any help is GREATLY appreciated!
my database has information about car manufacturerss and their id numbers:
ie
honda, ID 50-1
honda, ID 50-2
honda, ID 50-3
toyota, ID 99-1
toyota, ID 99-2
I have a form that displays each of these records. There is also a combo box that the user can open to find a record and update the information in the form based on the selection made in the combo box. This combo box, when opened, displays the car manufacturer and ID # in exactly the same fashion as above.
here is the code i am using.....
Private Sub Form_Current()
'Displays Car Manufacturer in combo box
Combo36 = CarManufacturer
Sub Combo36_AfterUpdate()
' Find the record that matches the control.
Me.RecordsetClone.FindFirst "[CarManufacturer] = '" & Me! [Combo36] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark
End Sub
Here's my problem:
no matter which selection I make in the combo box, be it honda ID50-1, honda ID50-2, honda ID50-3, the form is updated based on the honda record with the FIRST id # (honda 50-1).
Same thing happens with any toyota record.
So if I open the combo box and select honda ID50-3, the form will show the information for Honda ID50-1. Why???
How do I fix this?
Any help is GREATLY appreciated!
Last edited: