Hi,
I'm trying to pass a value from a form to a report. In my report I do this when a button is clicked:
DoCmd.OpenReport stDocName, acPreview, , , , "2008"
On the report in the _Open event, I do this:
Dim dateString As String
dateString = Me.OpenArgs
I get an error saying 'Invalid use of Null', and through debugging I can see that Me.OpenArgs is null.
I don't understand what I am doing wrong. Any ideas??
I'm trying to pass a value from a form to a report. In my report I do this when a button is clicked:
DoCmd.OpenReport stDocName, acPreview, , , , "2008"
On the report in the _Open event, I do this:
Dim dateString As String
dateString = Me.OpenArgs
I get an error saying 'Invalid use of Null', and through debugging I can see that Me.OpenArgs is null.
I don't understand what I am doing wrong. Any ideas??