Hi,
I develop an application in vb6 + crystal report 8.5. whenever i run a report application generate tmp file with 0k.
how can i remove these files.
Regards.
Crystal Reports may generate some temporary files ('*.tmp', '*.rpt') in a temp folder (typically the c:windowstemp folder or you temp folder in "Local Settings"). This is not a big deal because these files are quite small (between 0k and 200k for the ones I have seen during my investigations) but it can be a potential problems as they are very numerous (till 10 for a single export) and contains some potentially sensitive information (some data of your exports).
I have seen that these files are generated by the following methods:
SetDataSource
ExportToStream
How to correct this problem ?
Be sure to call the "Close()" method on your report object. This will automatically delete all the temporary generated files. In fact almost all of them as you will still have a "temp_xxx.rpt" file generated, even if you call the ExportToStream method.
Be sure to call the "Dispose()" method so Crystal Reports will release all the locks it may have on the object and the last generated file will be deleted
Of course, you could call only the "Dispose()" method as it will call internally the "Close()" method, or even not calling any of them but using the "using" syntax
Last Wiki Answer Submitted: June 11, 2009 2:58 am by Manojpatil200015 pts.
If you live outside the United States, by submitting your email address you consent to having your personal data transferred to and processed in the United States.
The Dispose() method in’st available in VB6 + CR8 or CR9…
In fact, the Dispose() method is availabe in .NET versions…