B
Bonnie43
I have a button with code attached, that once clicked will envoke the
following. I would prefer to view first prior to printing, as there are many
pages (10 reports). What would I add to this code to get it to work, or is it
possible?
Dim strWhere As String
If Me.Dirty Then 'Save any edits.
Me.Dirty = False
End If
If Me.NewRecord Then 'Check there is a record to preview
MsgBox "Select a record to view"
Else
strWhere = "[employeeid] = " & Me.[EmployeeID]
DoCmd.OpenReport "W-4", acViewNormal, , strWhere
following. I would prefer to view first prior to printing, as there are many
pages (10 reports). What would I add to this code to get it to work, or is it
possible?
Dim strWhere As String
If Me.Dirty Then 'Save any edits.
Me.Dirty = False
End If
If Me.NewRecord Then 'Check there is a record to preview
MsgBox "Select a record to view"
Else
strWhere = "[employeeid] = " & Me.[EmployeeID]
DoCmd.OpenReport "W-4", acViewNormal, , strWhere