G
graeme34
Hi could anybody help me?
I am trying to use the following code to populate a forms controls from a
combo box, the code from the combo box after update is as follows
Private Sub cboMoveTo_AfterUpdate()
Dim rs As DAO.Recordset
If Not IsNull(Me.cboMoveto) Then
'Save before move.
If Me.Dirty Then
Me.Dirty = False
End If
'Search in the clone set.
Set rs = Me.RecordsetClone
'Stop
rs.FindFirst "[AccountIndex] = """ & Me.cboMoveto & """"
'Display the found record in the form.
Me.Bookmark = rs.Bookmark
'Stop
rs.Close
End If
End Sub
I have placed a couple of stop statements to test where it was going wrong it
seems the recordset is not working as the absolute position is = -1. Yet I
have used similar code in another form and it worked fine.....??? Any help
would be greatly appreciated.
Graeme
I am trying to use the following code to populate a forms controls from a
combo box, the code from the combo box after update is as follows
Private Sub cboMoveTo_AfterUpdate()
Dim rs As DAO.Recordset
If Not IsNull(Me.cboMoveto) Then
'Save before move.
If Me.Dirty Then
Me.Dirty = False
End If
'Search in the clone set.
Set rs = Me.RecordsetClone
'Stop
rs.FindFirst "[AccountIndex] = """ & Me.cboMoveto & """"
'Display the found record in the form.
Me.Bookmark = rs.Bookmark
'Stop
rs.Close
End If
End Sub
I have placed a couple of stop statements to test where it was going wrong it
seems the recordset is not working as the absolute position is = -1. Yet I
have used similar code in another form and it worked fine.....??? Any help
would be greatly appreciated.
Graeme