Visual Studio: Hit a debugger breakpoint when a file is read

Add this Breakpoint as Function Breakpoint:

{,,kernel32.dll}ReadFile

Now Visual Studio will break as soon as the Windows kernel tries to read a file for your application under debugging.

Probably this does not catch all reads, as there is also ReadFileEx, ...

Leave a Reply

Your email address will not be published. Required fields are marked *