About the implementation of netstat using .NET Framework

I have spent plenty of time in implementing the functions of netstat by using .NET Framework2.0.

I found that I can implement some functions of netstat(for example, -np TCP, -s) when using the classes in NetworkInformation Namespace. But I don't how to implement the functions listed below:

netstat -r

netstat -e

Could anyone give me any suggestion?

[381 byte] By [wslee] at [2007-12-24]
# 1

You have one implementation for netstat in MSDN.

http://msdn2.microsoft.com/en-us/library/ks32hs88.aspx

Hope this helps.

DanielBogdan at 2007-8-31 > top of Msdn Tech,.NET Development,.NET Framework Networking and Communication...
# 2

You have one implementation for netstat in MSDN.

http://msdn2.microsoft.com/en-us/library/ks32hs88.aspx

Hope this helps.

Its very useful!!!Thank you very much!

wslee at 2007-8-31 > top of Msdn Tech,.NET Development,.NET Framework Networking and Communication...
# 3
I don't think you can get routing table information from the
,NET APIs [-r opttion]
DurgaprasadGorti at 2007-8-31 > top of Msdn Tech,.NET Development,.NET Framework Networking and Communication...
# 4

I don't think you can get routing table information from the
,NET APIs [-r opttion]

Yes, you are right, maybe. Till now, I can't find a way to implement the function of the [-r] option.

Could you give me any suggestion?

wslee at 2007-8-31 > top of Msdn Tech,.NET Development,.NET Framework Networking and Communication...
# 5

You may need to P/Invoke. See the native IP Helpers APIs.

http://windowssdk.msdn.microsoft.com/en-us/library/ms691203.aspx

MikeFlasko at 2007-8-31 > top of Msdn Tech,.NET Development,.NET Framework Networking and Communication...

.NET Development

Site Classified