When you try to delete a file in Windows Explorer and this file is used, it opens a dialog box with the inscription File is used and displays the name of the file in which this file is open.
For instance,

I saw hacks with kernel drivers, but if Windows Explorer can do this, then there should be an easier way.
What is the best and easiest way to get this information?
source
share