Show Active TCP connections

2

I'm trying to show all open TCP connections. But in my Code I'm getting following error:

System.PlatformNotSupportedException HResult=0x80131539 Nachricht = Operation is not supported on this platform.

System.Net.NetworkInformation.NetNativeIPGlobalProperties.GetActiveTcpConnections()

And here is my Code, is the problem, that UWP doesn't support TcpConnectionInformation?:

try
{
    IPGlobalProperties properties = IPGlobalProperties.GetIPGlobalProperties();
    TcpConnectionInformation[] connections = properties.GetActiveTcpConnections();
    foreach (TcpConnectionInformation c in connections)
    {
        Liste.Items.Add(c.LocalEndPoint.ToString());
    }
}
catch (Exception e1)
c#
tcp
uwp
asked on Stack Overflow Dec 28, 2017 by flaeckli • edited Dec 28, 2017 by TheGeneral

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0