Unanswered: how do you dynamically set a report's recordset?
I've got a simple report in Access XP that could display data from one of two queries. What I'd like to do is open the report and attach the right data to it, depending on what was asked by the user. The data is coming from a stored procedure on SQL Server that has input parameters (hence the varying data). The recordset schema that is returned is always the same, of course.
Access tells me that I can't set a recordset or recordsource property once the report has been displayed. So I tried to instantiate something (Set rpt = New Report_thereport) and set its recordset that way, then making it visible. No luck, as the report opens at instantiation.
I'm probably missing something obvious that you experienced Access people can tell me. Any help would be very much appreciated,
I haven't used openargs much previously, so when I got Access XP I thought I would try them out. I couldn't get them to work, so I ordered a new book, which still hasn't arrived as I decided I was missing something too. I'm wondering if the open args syntax or something has changed since 2000, as all my reference material is for 2000.