Click here to Skip to main content
15,919,358 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: modeless dialogs - ownmessage queue ? Pin
rrrado27-Jan-04 0:47
rrrado27-Jan-04 0:47 
QuestionHow to get CurrentDir of an application running in Embedded Visual C? Pin
ntnhan26-Jan-04 21:31
ntnhan26-Jan-04 21:31 
AnswerRe: How to get CurrentDir of an application running in Embedded Visual C? Pin
Michael P Butler27-Jan-04 1:57
Michael P Butler27-Jan-04 1:57 
GeneralUtility for checking dependencies Pin
rajeev26-Jan-04 21:31
rajeev26-Jan-04 21:31 
Generalmemory leak debugger Pin
Gérald Mercet26-Jan-04 21:16
Gérald Mercet26-Jan-04 21:16 
GeneralRe: memory leak debugger Pin
J. Eric Vaughan27-Jan-04 3:16
J. Eric Vaughan27-Jan-04 3:16 
Generaldifference between CSocket and CAsynSocket Recieve Call Pin
Atif Mushtaq26-Jan-04 20:20
Atif Mushtaq26-Jan-04 20:20 
GeneralRe: difference between CSocket and CAsynSocket Recieve Call Pin
RobJones27-Jan-04 3:03
RobJones27-Jan-04 3:03 
I would try to stay away from CSocket and CAsyncSocket (I have ran into lots of problems with both).. If you use standard WinSock and stay away from those wrapper classes it would be much easier.

Here is a example of how I might do the loop..

// This would keep looping until all the data is read, or a error occures.
char buff[4096];
int nRec;
while(nRec = recv(client,buff,sizeof(buff),0))
{
	// Error and its not WSAEWOULDBLOCK
	if((nRec == SOCKET_ERROR) && (nRec != WSAEWOULDBLOCK))
	{
		// Clean up and exit. (We have a problem)
		// You could do WSAGetLastError() to figure out
		// what exactly is happening.
	}
	else // Every thing is fine and dandy, keep looping until done.
	{
		// Store your info in this part		
	}
}


Hope this helps..
Rob




Whoever said nothing's impossible never tried slamming a revolving door!
GeneralRe: difference between CSocket and CAsynSocket Recieve Call Pin
Atif Mushtaq27-Jan-04 18:16
Atif Mushtaq27-Jan-04 18:16 
GeneralRe: difference between CSocket and CAsynSocket Recieve Call Pin
RobJones28-Jan-04 3:04
RobJones28-Jan-04 3:04 
GeneralRe: difference between CSocket and CAsynSocket Recieve Call Pin
RobJones28-Jan-04 3:59
RobJones28-Jan-04 3:59 
GeneralRe: difference between CSocket and CAsynSocket Recieve Call Pin
Atif Mushtaq28-Jan-04 5:16
Atif Mushtaq28-Jan-04 5:16 
GeneralRe: difference between CSocket and CAsynSocket Recieve Call Pin
Xiangyang Liu 刘向阳28-Jan-04 7:02
Xiangyang Liu 刘向阳28-Jan-04 7:02 
GeneralWindows hooks Pin
Abhi Lahare26-Jan-04 18:43
Abhi Lahare26-Jan-04 18:43 
GeneralEdit boxes Pin
calebcohoon26-Jan-04 17:18
calebcohoon26-Jan-04 17:18 
GeneralRe: Edit boxes Pin
P-Rex26-Jan-04 20:59
P-Rex26-Jan-04 20:59 
GeneralRe: Edit boxes Pin
Robert A. T. Káldy27-Jan-04 0:24
Robert A. T. Káldy27-Jan-04 0:24 
GeneralRe: Edit boxes Pin
calebcohoon27-Jan-04 5:40
calebcohoon27-Jan-04 5:40 
GeneralFinding version info of a DLL Pin
haritadala26-Jan-04 17:13
haritadala26-Jan-04 17:13 
GeneralRe: Finding version info of a DLL Pin
Tim Smith26-Jan-04 17:26
Tim Smith26-Jan-04 17:26 
GeneralRe: Finding version info of a DLL Pin
Anonymous26-Jan-04 17:29
Anonymous26-Jan-04 17:29 
GeneralRe: Finding version info of a DLL Pin
haritadala27-Jan-04 3:51
haritadala27-Jan-04 3:51 
GeneralRe: Finding version info of a DLL Pin
Tim Smith27-Jan-04 4:18
Tim Smith27-Jan-04 4:18 
GeneralSendKey Pin
BaldwinMartin26-Jan-04 16:28
BaldwinMartin26-Jan-04 16:28 
GeneralRe: SendKey Pin
Abin26-Jan-04 18:30
Abin26-Jan-04 18:30 

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.