How to delete a temporary file folder after the PDF file was generated?

DongLi (5 posts)
December 20, 2016 01:53 PM
Accepted Answer

Hi there,

I have been using adcrutil for years. There is an issue that sometimes when after the PDF file was generated from Crystal Reports, there may be left with a temporary file folder in the -exportfile directory. The folder name looks random such as: "~0c49e9e7d2864f7d8aa8d02dc22b1246". That needs our production server people to clean up. This bothers us.So the question is: how to automatically delete this temporary folder?

Thanks.

Dong

 

 

 

Bill Staff (599 posts)
December 20, 2016 02:33 PM
Accepted Answer

What version of Crystal Reports are you using?

Report Commander should remove the folder itself. You can add the "-verbose" option to the Report Commander command line and it will then log a message when it deletes the temp file. If that fails it will give you an error message. You can either use the "-logfile" option to save the output, or redirect the Report Commander console output to a file.

DongLi (5 posts)
December 20, 2016 03:34 PM
Accepted Answer

I am using sap crystal reports for MS Visual Studio. Sometimes Report Commander removes the temp folder. Sometimes it doesn't. So you think it has something to do with the version of CR?

Thanks.

 

Bill Staff (599 posts)
December 20, 2016 03:38 PM
Accepted Answer

Sorry--I meant to ask what version of Report Commander you are using. It doesn't matter what version of Crystal Reports you are using.

You should use the verbose option so we can see what the problem is. Either something is going wrong before it gets around to deleting the file, or something is preventing it from deleting the file. The verbose output should tell us more.

DongLi (5 posts)
December 20, 2016 03:53 PM
Accepted Answer
I asked our company's server admin. He said the Report Commander version is: 1.5.0.61.
DongLi (5 posts)
December 20, 2016 03:56 PM
Accepted Answer
Here is the temp folder. We just had one left over from this morning.

Attachments

DongLi (5 posts)
December 20, 2016 04:07 PM
Accepted Answer
I will add the verbose option after the Xmas. And let you know the results. Thanks. Happy Holidays!

Replies are disabled for this topic.