Hi. im trying to setup a filter for a report. Let me explain what I would like to achieve. I have a form called Invoicing, here all the data is put in about the invoice, I then have a report also called invoicing. I would like to be on the invoicing form and click a button saying view invoice, this then takes the invoice number from the form and filters out all the other invoices so only that 1 invoice is shown.
Details of the fields, forms and reports:
Report Details:
Report name: Invoicing
The invoice number field is called: Invoice Number
Form details:
Form name: Invoicing
The invoice number field is called: Invoice Number
I have tried putting the following code into the reports on open event procedure:
Private Sub Report_Open(Can cel As Integer)
Me.Filter = "Invoice Number = " & Form_Invoicing.[Invoice Number].Value
Me.FilterOn = True
End Sub
Can some one please help me.
Details of the fields, forms and reports:
Report Details:
Report name: Invoicing
The invoice number field is called: Invoice Number
Form details:
Form name: Invoicing
The invoice number field is called: Invoice Number
I have tried putting the following code into the reports on open event procedure:
Private Sub Report_Open(Can cel As Integer)
Me.Filter = "Invoice Number = " & Form_Invoicing.[Invoice Number].Value
Me.FilterOn = True
End Sub
Can some one please help me.
Comment