Reputation: 624
I would like to know if the temporary folder of the application is emptied automatically. If so, when is this done?
Upvotes: 5
Views: 2031
Reputation: 15758
The Temporary folder can be cleaned up automatically whenever the device reaches a low-storage threshold.
The temporary app data store works like a cache. Its files do not roam and could be removed at any time. The System Maintenance task can automatically delete data stored at this location at any time. The user can also clear files from the temporary data store using Disk Cleanup. Temporary app data can be used for storing temporary information during an app session. There is no guarantee that this data will persist beyond the end of the app session as the system might reclaim the used space if needed.
The key point here is that anything you put in Temporary folder cannot be relied upon at a later time/after the current app session. For more info, please see Temporary app data.
And here are some best practices for Temporary folder:
Upvotes: 4