Hi super-brains,
I am finding that Access crashes on a line of code and I receieve the "Microsoft Access has encountered a problem and needs to close" type message.
The offending line is:
where sReportObj is the user chosen report name.
I have tried substituting each variable to test whether it's something going wrong, but that doesn't seem to make a difference. Worryingly, I've managed to use this code in another Db, so I am starting to worry that thier behaviour pointing towards a corrupt Db.
Looking through other threads on the forum, someone else has encountered the problem. They were exporting to text format however and was able to substitiute OutpputTo with TransferText. I am not able to use TransferSpreadsheet as I am outputting a report and not a table.
Any help greatly appreciated.
I am finding that Access crashes on a line of code and I receieve the "Microsoft Access has encountered a problem and needs to close" type message.
The offending line is:
Code:
DoCmd.OutputTo acOutputReport, sReportObj, "Biff8", , True
where sReportObj is the user chosen report name.
I have tried substituting each variable to test whether it's something going wrong, but that doesn't seem to make a difference. Worryingly, I've managed to use this code in another Db, so I am starting to worry that thier behaviour pointing towards a corrupt Db.
Looking through other threads on the forum, someone else has encountered the problem. They were exporting to text format however and was able to substitiute OutpputTo with TransferText. I am not able to use TransferSpreadsheet as I am outputting a report and not a table.
Any help greatly appreciated.