By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,326 Members | 1,932 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,326 IT Pros & Developers. It's quick & easy.

Print Log

P: n/a
I have been experimenting with a Print Log which runs from the
ReportHeader. However, I would like to be able to print a report to a
number of receipents based on one report.

The print log as issued by MS works but does not log each receipent,
only the one report. Is there a way to do this.

The code is as follows from MS

Option Compare Database
Option Explicit

Private Sub Report_Activate()
Flag = 0
End Sub
Private Sub Report_Deactivate()
Flag = -1
End Sub

Private Sub ReportHeader_Print(Cancel As Integer, PrintCount As
Integer)
Dim dbs As Database, rst As Recordset
Set dbs = CurrentDb()
Set rst = dbs.OpenRecordset("tblPrintedReports")
Dim Msg As String
Flag = Flag + 1

' If the current value of Flag = 1, then a hard copy of the
' report is printing, so add a new record to the history table.

If Flag = 2 Then

rst.AddNew
rst!ReportName = Me.Name 'I added this instead of a fixed name
rst!PrintDate = Now
rst.Update

Nov 13 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.