I’m trying to find what changes are made to the registry or what processes started. For example: If I change the view of windows-explorer to show hidden files and folders – I want to see which registry entry changed by that.
It has been suggested to use Process monitor, but a) there are too many registry accesses, and b) I couldn’t find any change to the registry there. (Though I remember reading it is a change to the registry that controls that)
I’m doing this because I then want my program to do the same things.
An answer in C# would be fine.
RegNotifyChangeKeyValue() is the system function you need to call. I’ve never seen anybody try to use it from C#, but getting to it should require no more trouble than calling any other unmanaged code. Basically, you call it, it returns after the first change is made, you call it again and wait for the next chande.
http://msdn.microsoft.com/en-us/library/windows/desktop/ms724892%28v=vs.85%29.aspx
has a fairly good description of its use.