G
Guest
I have two seperate fields, Student Name and Stud ID. On a form, I have one combo box for Student Name and im trying unsuccessfully to have the corresponding Student Number generate itself in a seperate combo box when the name has been selected. Ive tried using the following code
Private Sub Combo5_AfterUpdate(
' Find the record that matches the control
Dim rs As Objec
Set rs = Me.Recordset.Clon
rs.FindFirst "[Stud_ID] = '" & Me![Combo5] & "'
If Not rs.EOF Then Me.Bookmark = rs.Bookmar
End Su
where combo5 is the student name. i get the following error message when i try to select a name in form view
"Run time error '91
Object variable or With block variable not set
Its been a long time since ive used code before so i havn't the foggiest. I will be grateful for any help. Cheers
Private Sub Combo5_AfterUpdate(
' Find the record that matches the control
Dim rs As Objec
Set rs = Me.Recordset.Clon
rs.FindFirst "[Stud_ID] = '" & Me![Combo5] & "'
If Not rs.EOF Then Me.Bookmark = rs.Bookmar
End Su
where combo5 is the student name. i get the following error message when i try to select a name in form view
"Run time error '91
Object variable or With block variable not set
Its been a long time since ive used code before so i havn't the foggiest. I will be grateful for any help. Cheers