Click here to Skip to main content
16,006,378 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: file copy with progress. PinPopular
Randor 27-Nov-10 11:44
professional Randor 27-Nov-10 11:44 
GeneralRe: file copy with progress. Pin
Richard MacCutchan27-Nov-10 21:54
mveRichard MacCutchan27-Nov-10 21:54 
GeneralRe: file copy with progress. Pin
emmmatty127-Nov-10 22:41
emmmatty127-Nov-10 22:41 
QuestionLpt Capture. Pin
Ben Mess27-Nov-10 6:08
Ben Mess27-Nov-10 6:08 
QuestionSend file through socket likes yahoo Pin
darknguyen1748827-Nov-10 4:46
darknguyen1748827-Nov-10 4:46 
AnswerRe: Send file through socket likes yahoo Pin
Richard MacCutchan27-Nov-10 5:25
mveRichard MacCutchan27-Nov-10 5:25 
GeneralRe: Send file through socket likes yahoo Pin
darknguyen1748828-Nov-10 4:47
darknguyen1748828-Nov-10 4:47 
GeneralRe: Send file through socket likes yahoo Pin
Richard MacCutchan28-Nov-10 6:03
mveRichard MacCutchan28-Nov-10 6:03 
As I said before look at your server code; this is what you have:
while(nfilerecv < lenFile)
{
        //receive byte
    nfilerecv += recv(sock.sk,buffer,buffLength,0);
}
    m_msgString+=name_array[i_send];
    m_msgString+=":";
    m_msgString+=mess;
    m_msgString+="\r\n";
    UpdateData(FALSE);
}
else
    UpdateData(FALSE);

    delete buffer;
    return;
}

There is obviously an if statement missing there so I have no idea what you are trying to do in the missing code. There is nothing special about transferring the contents of a file between two systems. You just need to tell the receiving system how much data to expect so it waits until everything is received, and this would normally be done within a loop of continuous recv() calls, until either the total amount of data is transferred or some other indication that the transfer is complete.
Just say 'NO' to evaluated arguments for diadic functions! Ash

AnswerRe: Send file through socket likes yahoo Pin
Chuck O'Toole28-Nov-10 7:12
Chuck O'Toole28-Nov-10 7:12 
Questionmember function don't pass to class!!!??? Pin
hasani200727-Nov-10 2:33
hasani200727-Nov-10 2:33 
AnswerRe: member function don't pass to class!!!??? Pin
Richard MacCutchan27-Nov-10 2:53
mveRichard MacCutchan27-Nov-10 2:53 
QuestionHoa can find sound play by MCIWndPlay is end now? Pin
Le@rner26-Nov-10 21:03
Le@rner26-Nov-10 21:03 
AnswerRe: Hoa can find sound play by MCIWndPlay is end now? Pin
Richard MacCutchan27-Nov-10 1:33
mveRichard MacCutchan27-Nov-10 1:33 
QuestionHow can I load put a swf in resources and how to load it Pin
rahul.kulshreshtha26-Nov-10 19:55
rahul.kulshreshtha26-Nov-10 19:55 
AnswerRe: How can I load put a swf in resources and how to load it Pin
Richard MacCutchan26-Nov-10 22:50
mveRichard MacCutchan26-Nov-10 22:50 
GeneralRe: How can I load put a swf in resources and how to load it Pin
rahul.kulshreshtha27-Nov-10 2:02
rahul.kulshreshtha27-Nov-10 2:02 
GeneralRe: How can I load put a swf in resources and how to load it Pin
rahul.kulshreshtha28-Nov-10 22:10
rahul.kulshreshtha28-Nov-10 22:10 
GeneralRe: How can I load put a swf in resources and how to load it Pin
Richard MacCutchan29-Nov-10 3:27
mveRichard MacCutchan29-Nov-10 3:27 
Question[Solved]My CAsyncSocket class doesn't receive data after some secondes. [modified] Pin
stephen_young26-Nov-10 18:16
stephen_young26-Nov-10 18:16 
GeneralRe: My CAsyncSocket class doesn't receive data after some secondes. Pin
Randor 28-Nov-10 5:57
professional Randor 28-Nov-10 5:57 
GeneralRe: My CAsyncSocket class doesn't receive data after some secondes. Pin
stephen_young28-Nov-10 17:02
stephen_young28-Nov-10 17:02 
AnswerRe: [Solved]My CAsyncSocket class doesn't receive data after some secondes. Pin
stephen_young5-Dec-10 17:39
stephen_young5-Dec-10 17:39 
Questionfatal error LNK1104: can not open file .lib Pin
AmbiguousName26-Nov-10 6:26
AmbiguousName26-Nov-10 6:26 
AnswerRe: fatal error LNK1104: can not open file .lib Pin
Richard MacCutchan26-Nov-10 6:32
mveRichard MacCutchan26-Nov-10 6:32 
GeneralRe: fatal error LNK1104: can not open file .lib Pin
AmbiguousName26-Nov-10 6:47
AmbiguousName26-Nov-10 6:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.