Re: Display report w/ input parameters
Hi,
How can I display a report from database window(w/o form) which had input parameters in its recordsource?
In the report_open event I passed in input paramters in the
I have global variables which I passed in as input parameters in the report’s recordsource. But these variables are no longer visible when the report is open from database window that caused the query no longer working. It display a blank report. How can I get it to display ?
I’m using AC2k, SQL Server 2K
Thanks!
Private Sub Report_Open(Cancel As Integer)
On Error GoTo Err_Report_Open
Dim str As String
str = "SELECT tblFinal_inspection.cust_name, tblFinal_inspection.cure_date, tblFinal_inspection.lotnum, " str = str & "..”
str = str & "WHERE tblFinal_inspection.lotnum = " & lot_n & " and tblSampling_data.sampling_data_id = " & sampling_id & ""
Me.RecordSource = str
DoCmd.Save acReport, "rptRmr"
Exit_Report_open:
Exit Sub
Err_Report_Open:
MsgBox err.Description
Resume Exit_Report_open
End Sub
Hi,
How can I display a report from database window(w/o form) which had input parameters in its recordsource?
In the report_open event I passed in input paramters in the
I have global variables which I passed in as input parameters in the report’s recordsource. But these variables are no longer visible when the report is open from database window that caused the query no longer working. It display a blank report. How can I get it to display ?
I’m using AC2k, SQL Server 2K
Thanks!
Private Sub Report_Open(Cancel As Integer)
On Error GoTo Err_Report_Open
Dim str As String
str = "SELECT tblFinal_inspection.cust_name, tblFinal_inspection.cure_date, tblFinal_inspection.lotnum, " str = str & "..”
str = str & "WHERE tblFinal_inspection.lotnum = " & lot_n & " and tblSampling_data.sampling_data_id = " & sampling_id & ""
Me.RecordSource = str
DoCmd.Save acReport, "rptRmr"
Exit_Report_open:
Exit Sub
Err_Report_Open:
MsgBox err.Description
Resume Exit_Report_open
End Sub