Click here to Skip to main content
15,914,795 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: IShellFolder2 Pin
Gary R. Wheeler27-Nov-04 2:07
Gary R. Wheeler27-Nov-04 2:07 
GeneralRe: IShellFolder2 Pin
Gurra_Koo27-Nov-04 9:55
Gurra_Koo27-Nov-04 9:55 
QuestionHow can i get the boot drive Pin
Monty226-Nov-04 21:40
Monty226-Nov-04 21:40 
AnswerRe: How can i get the boot drive Pin
Alexander M.,27-Nov-04 9:28
Alexander M.,27-Nov-04 9:28 
Questionhow to prohibit a window maximizing in api?thanks Pin
cjwin8326-Nov-04 21:33
cjwin8326-Nov-04 21:33 
AnswerRe: how to prohibit a window maximizing in api?thanks Pin
PJ Arends26-Nov-04 21:40
professionalPJ Arends26-Nov-04 21:40 
QuestionHow to draw Dashed Ellipse in Embedded VC++ Pin
Arun AC26-Nov-04 20:39
Arun AC26-Nov-04 20:39 
GeneralLittle Doubt Using Send Message Pin
ThatsAlok26-Nov-04 20:38
ThatsAlok26-Nov-04 20:38 
As MSDN state,
The SendMessage function sends the specified message to a window or windows. It calls the window procedure for the specified window and does not return until the window procedure has processed the message.

I am facing Problem in this?i just want to transfer data back from the SendMessage,The way The ListView and etc work.

here is my code listing

on_click()<br />
{<br />
char nam1[255];<br />
nam1[0]=NULL;<br />
this->UpdateData(FALSE);<br />
::SendMessage((HWND)this->m_lHandle,WM_USER+90,0,(LPARAM)&nam1);<br />
<br />
MessageBox(nam1);<br />
}

and message Handlling

on_message()<br />
{<br />
char *nam1=(char*)lParam;<br />
<br />
char Text[100];<br />
sprintf(Text,"%u",nam1);<br />
//Address is ,macthes here<br />
::MessageBox(NULL,Text,"address of Nam1",MB_OK);<br />
strcpy(nam1,"codeproject");<br />
::MessageBox(NULL,Text,"kola",MB_OK);<br />
<br />
}

Both of Code working Fine, but name Variable contain some garbage value insist of codeproject

Any help is greatly apreciated


-----------------------------
"I Think this Will Help"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
GeneralRe: Little Doubt Using Send Message Pin
PJ Arends26-Nov-04 20:53
professionalPJ Arends26-Nov-04 20:53 
GeneralRe: Little Doubt Using Send Message Pin
ThatsAlok26-Nov-04 22:36
ThatsAlok26-Nov-04 22:36 
GeneralRe: Little Doubt Using Send Message Pin
PJ Arends26-Nov-04 23:00
professionalPJ Arends26-Nov-04 23:00 
GeneralRe: Little Doubt Using Send Message Pin
ThatsAlok26-Nov-04 23:03
ThatsAlok26-Nov-04 23:03 
GeneralRe: Little Doubt Using Send Message Pin
ThatsAlok26-Nov-04 23:37
ThatsAlok26-Nov-04 23:37 
GeneralRe: Little Doubt Using Send Message Pin
PJ Arends27-Nov-04 0:07
professionalPJ Arends27-Nov-04 0:07 
GeneralRe: Little Doubt Using Send Message Pin
ThatsAlok27-Nov-04 0:34
ThatsAlok27-Nov-04 0:34 
Questioncustom DWebBrowserEvents2 Interface? Pin
tkarven26-Nov-04 16:20
tkarven26-Nov-04 16:20 
GeneralPlease help me CPP Pin
bluehai26-Nov-04 16:02
bluehai26-Nov-04 16:02 
GeneralRe: Please help me CPP Pin
Anonymous26-Nov-04 21:44
Anonymous26-Nov-04 21:44 
GeneralRe: Please help me CPP Pin
bluehai26-Nov-04 23:54
bluehai26-Nov-04 23:54 
QuestionHow come no one has ever posting code related to USB port Pin
paracha326-Nov-04 15:50
paracha326-Nov-04 15:50 
AnswerRe: How come no one has ever posting code related to USB port Pin
Gary R. Wheeler27-Nov-04 2:14
Gary R. Wheeler27-Nov-04 2:14 
GeneralCurrent User Pin
BaldwinMartin26-Nov-04 13:35
BaldwinMartin26-Nov-04 13:35 
GeneralRe: Current User Pin
ThatsAlok26-Nov-04 17:20
ThatsAlok26-Nov-04 17:20 
GeneralRe: Current User Pin
BaldwinMartin27-Nov-04 9:47
BaldwinMartin27-Nov-04 9:47 
GeneralRe: Current User Pin
ThatsAlok28-Nov-04 17:27
ThatsAlok28-Nov-04 17:27 

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.