you check to see if the query in the report has zero recs:
have a table ,tRpts2Print to hold the reports you want to print
it has 2 fields: Qry, Rpt. (the query in the report, and the name of the report)
the code below gets each report, 1 by 1,
checks if the query has records in it, if so, print it
Code:
Public Sub PrintRptsViaQry()
'PrintIfRecs "qsQry1", "rRpt1"
Dim rst
Dim sSql As String
Dim vQry, vRpt
sSql = "Select * from tRpts2Print"
Set rst = CurrentDb.OpenRecordset(sSql)
With rst
While Not .EOF
vQry = .Fields("Qry").Value
vRpt = .Fields("Rpt").Value
PrintIfRecs vQry, vRpt
.MoveNext
Wend
Set rst = Nothing
End With
End Sub
Public Sub PrintIfRecs(ByVal pvQry, ByVal pvRpt)
If DCount("*", pvQry) > 0 Then DoCmd.OpenReport pvRpt
End Sub