Sign in to follow this  

How to perform connectionless data transfer?

This topic is 2653 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm using .NET C# in VS 2008.

I've performed connection oriented data transfer using Sockets.

But I want to broadcast a message in a LAN, and the suitable process accepting the packet has to reply to the sender.

Ques... How to do this? Is it also performed using sockets?
Every socket has two endpoints.
For sender these are <Senders Address>, <Broadcast Address>
For receiver, <Receivers Address>, <Senders Address>
But the senders address is unknown and hence its remote end point is not defined, so how to do it using sockets??

Ques... Do I have to include the sender's IP in the packet??

Share this post


Link to post
Share on other sites
For a broadcast you use the broadcast address for the local network. You generally also want to use datagram protocol rather than a stream protocol.

Share this post


Link to post
Share on other sites
Can't we use Socket at the server (instead of UdpClient) by setting the required protocol and not binding it to any IP?

Whats the difference between this and the UdpClient method?

Share this post


Link to post
Share on other sites

This topic is 2653 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this