Private Sub Command0_Click()
On Error GoTo Err_Command0_Click
Const TableName As String = "Practices"
Const ReportName As String = "MyReport"
Dim strCriteria As String
Dim db As DAO.Database
Dim rs As DAO.Recordset
Dim strName As String
Set db = CurrentDb()
Set rs = db.OpenRecordset(TableName, dbOpenForwardOnly)
Do While Not rs.EOF
strCriteria = "[PRACT_ID] = " & rs("PRACT_ID")
DoCmd.OpenReport ReportName, acViewNormal, , strCriteria
rs.MoveNext
Loop
Exit_Command0_Click:
Set rs = Nothing
Set db = Nothing
Exit Sub
Err_Command0_Click:
MsgBox Err.Description, vbExclamation, "Error #" & Err.Number
Resume Exit_Command0_Click
End Sub