Hello guys,
I have been looking for a solution to this all afternoon but i can't figure this out. My apologies but i am very new to access.
I want to open multiple reports at once in a print preview of different id's. So far the report does open but it will only open one id and not the range of id's.
I have 2 textboxes in my form, one with a value "from" and one with a value "to". These values refer to the id the report uses.
Here is my code:
I have been looking for a solution to this all afternoon but i can't figure this out. My apologies but i am very new to access.
I want to open multiple reports at once in a print preview of different id's. So far the report does open but it will only open one id and not the range of id's.
I have 2 textboxes in my form, one with a value "from" and one with a value "to". These values refer to the id the report uses.
Here is my code:
Code:
Private Sub btnPrintRange_Click()
DoCmd.OpenReport "rptInvoice", acViewPreview, , "[invoicenumber] BETWEEN " & Me.from & " AND " & Me.to
End Sub