Datagram and Thread
Posted on 2003-03-29
Hi Every one,
I am new to C++ and I need help in the following so badly.
I wanted to write one program in C++ under Window. The program use Datagram Socket or Raw Socket and use the UDP protorol. When the program start, I wanted it to fire a thread that will be always runing independent of the rest of the program. The fired thread, will be just used for listening for incoming packets. Now after the thread is fired, the program should continue while the thread is listening and prompt the user for input. Once the user input the required information, the program will take these inputs and pass it to another method that use the info to send packets to another machine.
I tired to do this but I never was able to have the thread and the rest of program to be runing at the same time.
A sample program, or a like to a web page that address this problem will be great.