The revolutionary project management tool is here! Plan visually with a single glance and make sure your projects get done.
(SELECT TOP 1 [Payment Receipts].[Receipt Number] FROM [Payment Receipts] WHERE [Renter Space Assignments].[Space Number] = Forms![Rental Property Management]![Payment Receipts_Space Number] ORDER BY [Payment Receipts].[Receipt Number] DESC)
Private Sub Payment_Receipts_Space_Number_AfterUpdate()
Dim RecVar As Variant
Dim MatchVar As Variant
Dim TableVar As Variant
MatchVar = Me![Payment Receipts_Space Number]
TableVar = [Renter Space Assignments].[Space Number]
RecVar = DLookup("[Receipt Number]", "Payment Receipts", "'" & TableVar & " = " & "'" & MatchVar & "'")
Me![Receipt Number].SetFocus
DoCmd.FindRecord (RecVar), acAnywhere, False, acSearchAll, False, acCurrent, True
End Sub
Me.Recordset.FindLast "[Renter Space Assignments_Space Number] = [Payment Receipts_Space Number]"
Me.Recordset.FindLast "[Renter Space Assignments_Space Number] = " & [Payment Receipts_Space Number]
Me.RecordSet.MoveLast