I am trying to open a report showing only invoices from a date selected in a list box on the form. So the user selects the date, clicks the View Invoices button and the report displays only the invoices for the date selected. Problem is it is not showing any records. I've copied code from another post and added a Dim for my date field but it's not working I get a "Type" error in the first field of the report.
Dim sReportName As String
Dim sFilter As String
Dim InvDt As Date
InvDt = Me.lstInvDt.Column(0)
sReportName = "rptInvoice"
sFilter = "InvoiceDate = " & InvDt
Stop
DoCmd.RunCommand acCmdSaveRecord
DoCmd.OpenReport sReportName, acPreview, , sFilter
Any help is appreciated