Hi guys, im a newbie to C# having programmed with Java a fair amount.

Im currently writing my own (amateur) intrusion detection system and the reason i haven't done this in Java is that a friend told me it would be easier to access the OS using C#.

I was wondering if you guys could give me a few basics how to do something like check a port using the win32API in C# and I could use that as an example and go from there.

I have tried finding books on the subject, but only found a MSPress C/C++ on the api

Thanks in advance