Walker News

How To Copy Or Backup File That Is Open In Another Program?

When you are about to copy a file but Windows rejects you with a “File In Use” message, saying that “The action can’t be completed because the file is open in another program. Close the file and try again.”

Agree or not, that message box is a little bit informative but useless. It will be good by directly list out programs or Windows services that open or lock the file and provide an alternative option to copy the open file with API functions that already built into some latest Windows systems.

How to copy cache files from Google Chrome cache folder?
How to copy cache files from Google Chrome cache folder?

Sometime, it’s just impossible to close the program in order to copy the open file in question – you either can’t tell which particular program or Windows service is locking the file (unless using process viewer tool) or the program that open or lock the file can’t be closed by all means.

For example, if you want to copy the flash video cached by Flash Player plugin of Google Chrome, you’ve to copy the FLV file while the web browser remains open (i.e. the page that finish playback the flash video cannot be closed, otherwise the cached FLV file will be deleted immediately).

How to copy or backup an open file (i.e. a file locked by another process)?

So, you need VSS, short for Volume Snapshot Service! It’s also known as Volume Shadow Copy Service, Shadow Copy, Previous Version (in Windows Vista).
VSS was introduced in Windows XP SP1 and made available on all releases of Windows OS thereafter, is a set of COM interfaces that implements a framework to allow volume backups to be performed while applications on a system continue to write to the volumes. – cf Microsoft MSDN

If you’re using Windows XP SP1 and above or that VSS feature is available, a VSS-aware application will work to copy the open file from shadow copy rather than asking you to close the program that lock the file.

For example, I use HoboCopy to copy FLV files cached by Google Chrome’s Flash Player plugin, before I came to know a specific freeware called VideoCacheView.

Custom Search

2017  •  Privacy Policy