Hi there, I'm tring to clone a field where the previous field may be filtered out. If I turn off the filter this script works perfectly, however I need to restrict the form to only the relevant records.
This is the filter I'm using,
[Forms]![frmDepartment]![deptID]
And this is the recordclone proceedure.
Private Sub Form_Current
Dim rs1 As DAO.Recordset
Dim BKM As Variant
Dim vPRdolar As Variant
BKM = Me.Bookmark
Set rs1 = Me.RecordsetClone
rs1.Bookmark = BKM
rs1.MovePrevious
vPRdolar = rs1!regdollar
rs1.Close
Set rs1 = Nothing
Me.txtRegOldDol.Value = vPRdolar
End Sub
Is what I'm tring to accomplish here possible, or do I need to find another route?
Thanks,
--Toby Kliem-- sapere aude: Dare to be wise
This is the filter I'm using,
[Forms]![frmDepartment]![deptID]
And this is the recordclone proceedure.
Private Sub Form_Current
Dim rs1 As DAO.Recordset
Dim BKM As Variant
Dim vPRdolar As Variant
BKM = Me.Bookmark
Set rs1 = Me.RecordsetClone
rs1.Bookmark = BKM
rs1.MovePrevious
vPRdolar = rs1!regdollar
rs1.Close
Set rs1 = Nothing
Me.txtRegOldDol.Value = vPRdolar
End Sub
Is what I'm tring to accomplish here possible, or do I need to find another route?
Thanks,
--Toby Kliem-- sapere aude: Dare to be wise