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

C / C++ / MFC

 
AnswerRe: Writing to a file Pin
prasad_som31-Jul-07 0:56
prasad_som31-Jul-07 0:56 
QuestionPostthread message Pin
shakumar_2231-Jul-07 0:50
shakumar_2231-Jul-07 0:50 
AnswerRe: Postthread message Pin
prasad_som31-Jul-07 0:59
prasad_som31-Jul-07 0:59 
AnswerRe: Postthread message Pin
mandanani31-Jul-07 1:06
mandanani31-Jul-07 1:06 
GeneralRe: Postthread message Pin
mandanani31-Jul-07 1:17
mandanani31-Jul-07 1:17 
GeneralRe: Postthread message Pin
shakumar_2231-Jul-07 1:50
shakumar_2231-Jul-07 1:50 
GeneralRe: Postthread message Pin
James R. Twine31-Jul-07 3:03
James R. Twine31-Jul-07 3:03 
AnswerRe: Postthread message Pin
Iain Clarke, Warrior Programmer31-Jul-07 3:14
Iain Clarke, Warrior Programmer31-Jul-07 3:14 
Didn't I answer this yesterday?

As I said then - you are allocating a string on the stack. When you leave the function, it is destroyed. Some time later, your posted message is dealt with, the wp now points to junk.

In the first case, you are posting an address of a string built into the data segment of your program, so it will still be valid later.

Iain.
Questionprivilege given to a user [modified] Pin
sheetal_0631-Jul-07 0:48
sheetal_0631-Jul-07 0:48 
AnswerRe: privilege given to a user Pin
Nelek31-Jul-07 0:58
protectorNelek31-Jul-07 0:58 
QuestionRe: privilege given to a user Pin
Nelek31-Jul-07 0:58
protectorNelek31-Jul-07 0:58 
QuestionRe: privilege given to a user Pin
David Crow31-Jul-07 2:28
David Crow31-Jul-07 2:28 
GeneralRe: privilege given to a user Pin
Programm3r31-Jul-07 1:01
Programm3r31-Jul-07 1:01 
AnswerRe: privilege given to a user Pin
sheetal_0631-Jul-07 1:01
sheetal_0631-Jul-07 1:01 
QuestionCluster Detection Pin
Akin Ocal31-Jul-07 0:43
Akin Ocal31-Jul-07 0:43 
QuestionVC++ compilation Pin
Suneet.0331-Jul-07 0:41
Suneet.0331-Jul-07 0:41 
AnswerRe: VC++ compilation Pin
codeII31-Jul-07 1:14
codeII31-Jul-07 1:14 
QuestionMenu IDs turn to number! VS6.0 & MFC Pin
Hamed Musavi31-Jul-07 0:04
Hamed Musavi31-Jul-07 0:04 
AnswerRe: Menu IDs turn to number! VS6.0 & MFC Pin
Nelek31-Jul-07 0:39
protectorNelek31-Jul-07 0:39 
QuestionRe: Menu IDs turn to number! VS6.0 & MFC Pin
David Crow31-Jul-07 2:31
David Crow31-Jul-07 2:31 
AnswerRe: Menu IDs turn to number! VS6.0 & MFC Pin
Hamed Musavi31-Jul-07 2:34
Hamed Musavi31-Jul-07 2:34 
QuestionSame here with VC.NET 2003 Pin
jhwurmbach31-Jul-07 3:13
jhwurmbach31-Jul-07 3:13 
Question?? Pin
Nelek31-Jul-07 3:43
protectorNelek31-Jul-07 3:43 
AnswerRe: ?? Pin
Hamed Musavi31-Jul-07 4:10
Hamed Musavi31-Jul-07 4:10 
GeneralRe: ?? Pin
Nelek2-Aug-07 20:12
protectorNelek2-Aug-07 20:12 

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.