-
1
- #1
I'm experimenting with sockets by using the CSocket in MFC. This is what I would like to do, but not sure how. I've got my server and client programs to talk successfully, however, when the client is waiting on data from the server, it sticks there and the program doesn't go any further until the data is received (blocking socket? Someone correct me if I'm wrong). Another approach that I have seen is using the windows messaging to send a message to tell me the data has been received. So what I would like to do is start a thread everytime the client has successfully received data so that it is ready for the next string. My problem is with the thread. I have some varibles that I need to access in that thread that I have in my main program. Well, I can declare a global, but when I try and access it, it errors out. It seems like it SHOULD work. I'm guessing that when the thread exits, the variables get messed up somehow. I guess I just need some thoughts on how I can go about this. Maybe some tips from some of the Senior guys out there that have worked with this before and can give me some constructive criticism? Thanks in advance!
Niky Williams
NTS Marketing
Niky.Williams@NTSMarketing.com
Niky Williams
NTS Marketing
Niky.Williams@NTSMarketing.com