Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

TransmitFile

Status
Not open for further replies.

mattias1975

Programmer
Jul 26, 2004
36
SE
How do i use the socket function TransmitFile?
Can i send and receive files with it?

I have also a problem with reciving text with sockets.
I have a loop. And inside the loop i am calling the recv function.
But sometimes it is receiving old stuff that i have sent to it earlier. I am calling the closesocket function.
Do i have to do anything else? Call a method called disconnect or somthing like that?

Thank you.
 
Are you sure it is receiving stuff you sent earlier, or are you not zero-terminating (or memset it to NULL) your receive buffer? If you don't do that, sometimes you'll see garbage past the newly received stuff.
 
Status
Not open for further replies.

Similar threads

Part and Inventory Search

Sponsor

Back
Top