This question already has an answer here:
How to do an ICMP ping in a WinRT Modern UI application?
Ping is not implemented in WinRT currently (see related question here) and the previous strategies in Silverlight being:
- Use a WCF Service
- Call Javascript which then calls an ActiveX component
- Give up (here)
Vasily here uses http to 'ping' a webserver on a specific port using StreamSocket which supports network communication using a TCP socket.
Perhaps Windows.Networking.Sockets is the highest level API I have to use if I want to write my own ICMP library for WinRT..
This implementation uses System.Net.Sockets to make an ICMP echo request - in standard .NET
This WinRT sample uses the Windows.Networking.Sockets.DatagramSocket class to create a UDP socket. I think what I need is raw sockets to do ICMP.
Is this even possible in the WinRT sandbox to ICMP ping?
Something like:
full source here: github