You will need to use P/Invoke:
GetTcpTable can be used to get all the TCP connections.
[DllImport("iphlpapi.dll")]
public static extern int GetTcpTable( ... );
This article has example code.
Mitch Wheat
2009-07-22 02:01:04