Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Winsocket Problem

Posted on 1998-07-13
5
Medium Priority
?
168 Views
Last Modified: 2013-11-20
Is there any method to use Winsocket create a Broadcast application? Is that mean that I use UDP to send data to 255.255.255.255, then all the Subnet will receive the data?

I need a detailed sample. Thank you very much.
0
Comment
Question by:jonalee
  • 3
5 Comments
 
LVL 8

Expert Comment

by:trestan
ID: 1319071
There is an introduction and example codes about network communicaion.
http://devcentral.iftech.com/learning/tutorials/nt/nt3.asp
0
 
LVL 2

Author Comment

by:jonalee
ID: 1319072
I need more detailed thing about how to write the coding for broadcasting, not the NamePipe and MailSlot.

Thanks.

0
 
LVL 1

Accepted Solution

by:
saneesh100 earned 300 total points
ID: 1319073
I think the given hints will be enough for u to make a prog to do this..

1)   first make a socket of type SOCK_DGRAM
2)  change socket to SO_BROADCATS using setsockopt          function.
3) now u can use sendto fn with address  as 255.255.255.255

  the above was for the clinet( one who sends data,,)

and for server,, just use dgram socket.. with in a lopp with recvfrom any addrees INADDR_ANY ..

 if u need more detailed sample.. ican send u if u can send u'r email id..
 my id is saneesh@usa.net


0
 
LVL 2

Author Comment

by:jonalee
ID: 1319074
Thank you for the help
0
 
LVL 2

Author Comment

by:jonalee
ID: 1319075
Thank you for the help
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question