2
Reply

Data on udp port

Ask a question
Soumya B

Soumya B

14y
5.5k
1

How can we know, if any data(response) has arrived on an udp port after sending some request to another PC (for example) as shown below:

UdpClient socket = new UdpClient("10.99.8.97", 5555);

byte[] data = new byte[] { 0x0b, 0xaa, 0xbb };

socket.Send(data, data.Length);

This is required bcoz, the response received has to be parsed and the required data has to be displayed in the UI.

 


Answers (2)