F
Frank
I have an access 2002 database
I have an entry form in it
I have a command button that opens a report on it and reflects filtered
results.
What I want to do is this:
When clicking the report command button, I want the report to maxiuxm and
open to 115%.
I use the following code:
Function aadPreviewReport(frm As Form)
On Error GoTo Err_SmartFormError
Dim strReportName As String, strSQL As String
strSQL = "[" & stFormDataSource & "].[" & stFilterField & "] = Forms.["
& frm.Name & "].cmbFilterValue"
If IsNull(frm.cmbReports.Value) Or frm.cmbReports.Value = "" Then
Beep
Exit Function
Else
strReportName = frm.cmbReports
End If
If frm.tglFilter = True Then
DoCmd.OpenReport strReportName, acViewPreview,
Reports(strReportName).ZoomControl = 115, strSQL
Else
strSQL = vbNullString
DoCmd.OpenReport strReportName, acViewPreview,
Reports(strReportName).ZoomControl = 115, strSQL
End If
Any assitance is greatly appreciated.
I have an entry form in it
I have a command button that opens a report on it and reflects filtered
results.
What I want to do is this:
When clicking the report command button, I want the report to maxiuxm and
open to 115%.
I use the following code:
Function aadPreviewReport(frm As Form)
On Error GoTo Err_SmartFormError
Dim strReportName As String, strSQL As String
strSQL = "[" & stFormDataSource & "].[" & stFilterField & "] = Forms.["
& frm.Name & "].cmbFilterValue"
If IsNull(frm.cmbReports.Value) Or frm.cmbReports.Value = "" Then
Beep
Exit Function
Else
strReportName = frm.cmbReports
End If
If frm.tglFilter = True Then
DoCmd.OpenReport strReportName, acViewPreview,
Reports(strReportName).ZoomControl = 115, strSQL
Else
strSQL = vbNullString
DoCmd.OpenReport strReportName, acViewPreview,
Reports(strReportName).ZoomControl = 115, strSQL
End If
Any assitance is greatly appreciated.