L
Liz Hansen
Hello,
I have a form with a combo box and a couple of other text boxes. I want to
be able to select an employee in my drop down box and then populate the
other text boxes with data... But I have run into trouble using the
following code in the After Update code. I took this code from a silumar
form but in that case the FieldID was refering to a number field. In my new
form the FieldID happens to be a text field. Now, when running the code I
get a Data Type Mismatch error and I sort of understand why, but unfornuatly
I don't know how to correct it.
Private Sub Combo16_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[FieldID] = " & Str(Nz(Me![Combo16], 0))
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Anu suggestions are very much appriciated.
Many thanks!!
Liz
I have a form with a combo box and a couple of other text boxes. I want to
be able to select an employee in my drop down box and then populate the
other text boxes with data... But I have run into trouble using the
following code in the After Update code. I took this code from a silumar
form but in that case the FieldID was refering to a number field. In my new
form the FieldID happens to be a text field. Now, when running the code I
get a Data Type Mismatch error and I sort of understand why, but unfornuatly
I don't know how to correct it.
Private Sub Combo16_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[FieldID] = " & Str(Nz(Me![Combo16], 0))
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Anu suggestions are very much appriciated.
Many thanks!!
Liz