MS-Access VB: Can I set RecordSource of a Report without opening it?
Posted on 2003-02-23
Anyone knows if its possible to set RecordSource of a Report in VB without opening it? When you try to do that you get an error:
"report name misspelled or not open yet"
When you set it AFTER the report is open, you get an error:
"Can't set a RecordSource to an open report"
This is almost like this joke, that a painter shows a painting with just some gray smear and calls it "Israelis crossing the red see" - and when someone ask him why nothing is there, he replies that the Israelis already crossed and the Egyptians didn't come yet ...:)
The only way I found around it is opening the report in design mode, changing the RecordSource and closing, quite an ugly way.
Thanks for the help!