Has anybody encountered this problem that DoCmd.OutputTo acOutputQuery
deletes the query itself, the second time it is run?
Is there any workaround/patch for this bug (at least seems like a bug to me)?
Is there a better way to do this?
Has anybody encountered this problem that DoCmd.OutputTo acOutputQuery
deletes the query itself, the second time it is run?
Is there any workaround/patch for this bug (at least seems like a bug to me)?
Is there a better way to do this?
I think the behaviour you described "...deletes the query itself, the second time it is run" occurs when the query returns no records.
I could not recreate your error, even with a query that returned 0 records. Maybe your file was corrupt?
Are you including the objectname, Outputformat, and Output file in your code? Yor example did not include them.
Re: your comment.
Did you do a file copy, or did you copy the objects between two databases? IF the second, you might want to try doing a compact and repair on a file-copy of the original.
You might even want to try that on the real original.
Hi,
this also happening to me also right now.
you were able to fix this ?
cheers Alex
Hi, it happens to me too. I'm using Access 2003.
The only workaround I've found is to preserve a copy of the original mdb, this way I can restore the mdb when it happens.
It seems that Access 2007 doesn't have this problem.