Something like this cannot be done using C#. The only real reliable way of achieving something like this is to write a kernal-mode File System Filter Driver. If you install the WDK there is an example called minispy Minifilter Sample which would be a good starting point for you.