Question

How can I send a multicast ping in .NET ? So that all computers on the network respond ?

Was it helpful?

Solution

Assuming you mean "broadcast ping" (I get the two confused All The Time, myself):
Fetch the local network gateway IP, change the last byte to 255, ping that IP.

The main problem with your approach though is that the set of all devices on the network that will respond to a broadcast ping is typically much smaller than the set of all devices on the network. I've found that while most devices will respond to a direct ping, very few will respond to a broadcast ping. It's implementation dependant.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top