E
eschlep via AccessMonster.com
I am trying to print a form and I created a button that takes the form to a
report however it leaves out all of the subforms in the form. My code for
the button is
Private Sub Print_Click()
Dim strReportName As String
Dim strCriteria As String
If NewRecord Then
MsgBox "This record contains no data. Please select a record to print
or Save this record." _
, vbInformation, "Invalid Action"
Exit Sub
Else
strReportName = "LNREVIEWQ33"
strCriteria = "[Field2]= '" & Me![Field2] & "'"
DoCmd.OpenReport strReportName, acViewPreview, , strCriteria
End If
End Sub
Thanks
report however it leaves out all of the subforms in the form. My code for
the button is
Private Sub Print_Click()
Dim strReportName As String
Dim strCriteria As String
If NewRecord Then
MsgBox "This record contains no data. Please select a record to print
or Save this record." _
, vbInformation, "Invalid Action"
Exit Sub
Else
strReportName = "LNREVIEWQ33"
strCriteria = "[Field2]= '" & Me![Field2] & "'"
DoCmd.OpenReport strReportName, acViewPreview, , strCriteria
End If
End Sub
Thanks