I'm having an issue whereby the UDPClient receive only works if I disable all the network cards on the computer bar 1. If I'm using more than 1 network card it blocks forever. I can see the data coming over on wireshark so its there for me to recieve.
Anyway I'm aware there is an issue with multiple NICs but the suggested solution is to set a specific EndPoint in the UdpClient constructor with the IP of the NIC you wish to use. Code below:
public void ReceiveData()
{
try
{
receiveClient = new UdpClient(new IPEndPoint(AConfiguredIPAddressofOneOfMyNICs, port));
receiveClient.JoinMulticastGroup(IPAddress.Parse("240.0.0.1"));
IPEndPoint endPoint = new IPEndPoint(IPAddress.Any, 0);
Byte[] receiveBytes = receiveClient.Receive(ref endPoint); // blocks forever
Any ideas people?