3

I work on an application where we have the potential to attempt a file save in the top-level exception handler. The intention would be save a file which can then be sent into the support team, validated for corruption, and restored as far as possible. (We have a small enough customer base to work like this.)

Is there a convention for where to store such a file? I've seen %APPDATA%/Local/Temp used for one program - is that a mainstream idea, or just a one-off? Or would it be entirely up to me? Ideally, the user will be able to retrieve this file themselves. (AppData is normally hidden by default, I think?)

1
  • If you are asking about the Windows o/s, then please tag the question accordingly. The more information you can give us, the more help we can give you. – Mawg says reinstate Monica Oct 29 '15 at 13:54
1

The flaw with using [user]/AppData/Local/Temp is that it's a location that users (and tools) will delete to free hard drive space. If you want these files to stay around, I would avoid using Temp.

If you look at your %APPDATA% folder, you'll see that a common convention to use is %APPDATA%/[Vendor]/[Application] for any user specific data that an application wants to save.

For example, I have:

%APPDATA%/Microsoft/Office

%APPDATA%/JetBrains/Resharper

%APPDATA%/Adobe/Acrobat

1
  • Thanks 17. I'd thought of %APPDATA% as more 'settings' sort of files, but looking through, I did find a couple of corrupted/crash log style files. Cheers. – Chris Oct 30 '15 at 9:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.