Click here to Skip to main content
15,887,485 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Win98 system sometimes hangs on ExitWindowsEx() Pin
Still learning how to code28-Feb-05 21:00
Still learning how to code28-Feb-05 21:00 
GeneralRe: Win98 system sometimes hangs on ExitWindowsEx() Pin
Still learning how to code1-Mar-05 10:00
Still learning how to code1-Mar-05 10:00 
GeneralRe: Win98 system sometimes hangs on ExitWindowsEx() Pin
PJ Arends1-Mar-05 19:26
professionalPJ Arends1-Mar-05 19:26 
GeneralDebugging Header includes Pin
hyling28-Feb-05 10:38
hyling28-Feb-05 10:38 
GeneralRe: Debugging Header includes Pin
PJ Arends28-Feb-05 10:53
professionalPJ Arends28-Feb-05 10:53 
GeneralRe: Debugging Header includes Pin
vladfein28-Feb-05 11:53
vladfein28-Feb-05 11:53 
GeneralRe: Debugging Header includes Pin
hyling1-Mar-05 4:13
hyling1-Mar-05 4:13 
GeneralBYTE array question Pin
Tom Wright28-Feb-05 10:33
Tom Wright28-Feb-05 10:33 
I'm trying to pass a BYTE array in a winsock send function. Before I send this string I need to add a hex 00 and a hex 04 respectively, to the end of the string. I'm doing it this way:
<br />
			CString mySQLData = (char*)(_bstr_t)pRecordset->Fields->GetItem("MDC1_DATA_TEXT")->Value;<br />
			BYTE* myData = new BYTE[strlen(mySQLData) + 2];<br />
<br />
			memset(myData, 0x00, strlen(mySQLData) + 2);<br />
			memcpy(myData, mySQLData, strlen(mySQLData));<br />
			<br />
			myData[strlen(mySQLData) + 1] = 0x00;<br />
			myData[strlen(mySQLData) + 2] = 0x04;<br />
			iSent = m_sConnectSocket.Send(myData, strlen(mySQLData) + 2);<br />

When the other end of this socket connection receives this string the hex 00 and hex 04 are not there. Am I missing something here?

Thanks

Tom Wright
tawright915@yahoo.com
GeneralRe: BYTE array question Pin
Ryan Binns28-Feb-05 17:17
Ryan Binns28-Feb-05 17:17 
GeneralRe: BYTE array question Pin
Tom Wright1-Mar-05 3:31
Tom Wright1-Mar-05 3:31 
GeneralRe: BYTE array question Pin
zhang80060528-Feb-05 19:56
zhang80060528-Feb-05 19:56 
GeneralAPI &amp; Resizing the SysTray window Pin
Axonn Echysttas28-Feb-05 9:52
Axonn Echysttas28-Feb-05 9:52 
GeneralRe: API &amp; Resizing the SysTray window Pin
Ryan Binns28-Feb-05 17:19
Ryan Binns28-Feb-05 17:19 
GeneralRe: API &amp; Resizing the SysTray window Pin
Axonn Echysttas28-Feb-05 20:54
Axonn Echysttas28-Feb-05 20:54 
GeneralRe: API &amp; Resizing the SysTray window Pin
Ryan Binns28-Feb-05 23:30
Ryan Binns28-Feb-05 23:30 
GeneralRe: API &amp; Resizing the SysTray window Pin
Axonn Echysttas1-Mar-05 10:21
Axonn Echysttas1-Mar-05 10:21 
GeneralRe: API &amp; Resizing the SysTray window Pin
Ryan Binns1-Mar-05 15:21
Ryan Binns1-Mar-05 15:21 
GeneralRe: API &amp; Resizing the SysTray window Pin
Axonn Echysttas1-Mar-05 21:30
Axonn Echysttas1-Mar-05 21:30 
GeneralRe: API &amp; Resizing the SysTray window Pin
Axonn Echysttas2-Mar-05 11:47
Axonn Echysttas2-Mar-05 11:47 
GeneralRe: API &amp; Resizing the SysTray window Pin
Ryan Binns2-Mar-05 12:43
Ryan Binns2-Mar-05 12:43 
GeneralDrawText+DT_CALCRECT - width of last line Pin
peterchen28-Feb-05 9:44
peterchen28-Feb-05 9:44 
GeneralRe: DrawText+DT_CALCRECT - width of last line Pin
PJ Arends28-Feb-05 10:05
professionalPJ Arends28-Feb-05 10:05 
GeneralRe: DrawText+DT_CALCRECT - width of last line Pin
Ryan Binns28-Feb-05 17:26
Ryan Binns28-Feb-05 17:26 
GeneralRe: DrawText+DT_CALCRECT - width of last line Pin
peterchen28-Feb-05 20:14
peterchen28-Feb-05 20:14 
GeneralRe: DrawText+DT_CALCRECT - width of last line Pin
zhang80060528-Feb-05 20:19
zhang80060528-Feb-05 20:19 

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.