Hi, I'm far from new at Access programming, but I never needed to do this before.
The company has many Providers, each provider has many Clients, each Provider has visited each Client numerous times. Each Client has issues, ranging from the medical to the physical to the mental. The average duration is about an hour, so a Provider might see many Clients in a day's work. The final table, called tblSessions, contains many fields regarding the visit (called a "session"), beyond date, time, and duration. Because of their hectic work days, the Providers only enter their data once in two-four weeks, while keeping copious notes on each session.
The problem: they're not sure which entries they've completed and which ones still need to be entered. They want me to allow them to display the last 10 records they've entered. How do I program that? I'd rather program it rather than give them access to the live table. In VBA code, I've opened a Recordset, but it doesn't display the records. Please help.
The code:
Code:
Private Sub cmbSelectProvider_AfterUpdate()
Dim QrySession1 As QueryDef, rstQrySess1 As DAO.Recordset
Set QrySession1 = CurrentDb.QueryDefs("qrySessionQry1")
With QrySession1
.Parameters("Enter Initials") = Me.cmbSelectProvider.Value
Set rstQrySess1 = .OpenRecordset
.
.
.
.
End Sub
where qrySessionQry1 controls the data to be displayed. Thanks for your help. BTW, using the Immediate window, I've ascertained that Access is opening the correct records.