Hi guys, im currently a java programmer who would like to just learn the basics of using the win32api with C#.

On thing i wondered whether you guys could help me on is how to do things such as constantly read the value of a registry key and detect value changes.

Could anyone show me how c# uses the win32API? thanks

... why not use the .NET framework? You can hammer the registry with reads or implement a hook to detect changes. Take a look at Microsoft.Win32.RegistryKey.

To be honest i dont actually understand what .NET is compared with c#?

Consider .NET as a library.
Read the link provided by sknake. It contains examples on how to code in C# when using the registry.

Consider .NET as a library.
Read the link provided by sknake. It contains examples on how to code in C# when using the registry.

Sorry i completely overlooked that link

Just had a quick look and thats exactly what i was after!

I did a bit of googling and saw some nasty stuff requiring [<something>] and it looked a little messy

No problema:icon_wink:

Haha thanks!

If thats a '.NET library' when i install visual studio 2008 would that be all i need to start using all those registry functions?

Or would i need to do/install anything else to be able to reference them?

Yes that would be all.
If you installed VS 2008 C# you also have access to .NET, and believe me .NET is HUGE!

This article has been dead for over six months. Start a new discussion instead.