Click here to Skip to main content
       

ATL / WTL / STL

 
Questionhow to import COM interface methods in Win32 dll? Pinmemberlitu kumar30-Sep-12 19:58 
AnswerRe: how to import COM interface methods in Win32 dll? Pinmember«_Superman_»1-Oct-12 21:29 
GeneralOff topic PinmvpRichard MacCutchan2-Oct-12 2:55 
GeneralRe: Off topic Pinmember«_Superman_»2-Oct-12 3:00 
GeneralRe: Off topic PinmvpRichard MacCutchan2-Oct-12 3:23 
QuestionTooltip for ATL toolbar PinmemberSakhalean24-Sep-12 18:43 
QuestionCAsyncSocket Send( arguments ) [modified] Pinmemberbkelly1318-Sep-12 16:13 
AnswerRe: CAsyncSocket Send( arguments ) PinmvpRichard MacCutchan18-Sep-12 21:50 
bkelly13 wrote:
How should the arguments to Send() be written?
As described in the documentation[^] is usually the right way. In your case why would you cast to LPCTSTR when it specifically states to cast to const void*? So your code should look like:
int chars_sent = m_C_Server_Send_Time_Socket->Send((const void*)&m_current_time, t1,   0 );
Maybe a bit of a refresher about casts, pointers and the addressof operator would be useful.
One of these days I'm going to think of a really clever signature.

GeneralRe: CAsyncSocket Send( arguments ) Pinmemberbkelly1319-Sep-12 12:13 
AnswerRe: CAsyncSocket Send( arguments ) Pinmemberpasztorpisti29-Sep-12 23:52 
GeneralRe: CAsyncSocket Send( arguments ) PinmvpRichard MacCutchan30-Sep-12 1:07 
GeneralRe: CAsyncSocket Send( arguments ) Pinmemberpasztorpisti30-Sep-12 3:16 
GeneralRe: CAsyncSocket Send( arguments ) PinmvpRichard MacCutchan30-Sep-12 4:00 
GeneralRe: CAsyncSocket Send( arguments ) Pinmemberpasztorpisti30-Sep-12 4:07 
GeneralRe: CAsyncSocket Send( arguments ) Pinmemberpasztorpisti30-Sep-12 4:03 
GeneralRe: CAsyncSocket Send( arguments ) PinmvpRichard MacCutchan30-Sep-12 4:13 
GeneralRe: CAsyncSocket Send( arguments ) Pinmemberbkelly1330-Sep-12 5:44 
GeneralRe: CAsyncSocket Send( arguments ) PinmvpRichard MacCutchan30-Sep-12 6:10 
GeneralRe: CAsyncSocket Send( arguments ) Pinmemberpasztorpisti30-Sep-12 6:38 
GeneralRe: CAsyncSocket Send( arguments ) [modified] Pinmemberbkelly1330-Sep-12 6:16 
GeneralRe: CAsyncSocket Send( arguments ) [modified] Pinmemberpasztorpisti30-Sep-12 6:31 
Questionget instance of object (in exe) from dll caller Pinmemberkhaliloenit17-Sep-12 4:38 
AnswerRe: get instance of object (in exe) from dll caller Pinmemberpasztorpisti17-Sep-12 6:57 
GeneralRe: get instance of object (in exe) from dll caller Pinmemberkhaliloenit17-Sep-12 9:32 
JokeRe: get instance of object (in exe) from dll caller Pinmemberpasztorpisti17-Sep-12 13:43 

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

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


Advertise | Privacy | Mobile
Web02 | 2.8.140916.1 | Last Updated 12 Sep 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid