Click here to Skip to main content
15,888,610 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
JokeRe: About C++ on different OS? [THHB attempt] Pin
Cedric Moonen29-Jul-08 4:05
Cedric Moonen29-Jul-08 4:05 
GeneralRe: About C++ on different OS? [THHB attempt] Pin
Rajesh R Subramanian29-Jul-08 21:24
professionalRajesh R Subramanian29-Jul-08 21:24 
AnswerRe: About C++ on different OS? Pin
toxcct29-Jul-08 0:52
toxcct29-Jul-08 0:52 
AnswerRe: About C++ on different OS? Pin
CPallini29-Jul-08 0:53
mveCPallini29-Jul-08 0:53 
AnswerRe: About C++ on different OS? Pin
vikas amin30-Jul-08 11:08
vikas amin30-Jul-08 11:08 
QuestionRunTime Error : The instruction at "0x00000000" referenced memory at "0x00000000". The memory could not be "read". Pin
ptr_Electron29-Jul-08 0:33
ptr_Electron29-Jul-08 0:33 
AnswerRe: RunTime Error : The instruction at "0x00000000" referenced memory at "0x00000000". The memory could not be "read". Pin
Cedric Moonen29-Jul-08 0:47
Cedric Moonen29-Jul-08 0:47 
AnswerRe: RunTime Error : The instruction at "0x00000000" referenced memory at "0x00000000". The memory could not be "read". Pin
Joe Woodbury29-Jul-08 8:57
professionalJoe Woodbury29-Jul-08 8:57 
More specifically, the dialog box window likely hasn't been initialized at the time you called OnSearchBtn().

In addition to the previous solution, you could send a user message to the dialog box from the thread. I'm doing that in an application I'm working on right now.

In OnSearchBtn(), you should wrap the function contents in if (GetSafeHwnd()) {} to ensure it's only called when the window is valid.

(As a small note; to prevent problems in my current application I don't start the worker thread until the dialog box has been created. I do this by setting a short timer in OnInitDialog().)


Anyone who thinks he has a better idea of what's good for people than people do is a swine.
- P.J. O'Rourke


QuestionDialog as MDI mainframe window ? Pin
jalsa G29-Jul-08 0:01
jalsa G29-Jul-08 0:01 
QuestionRe: Dialog as MDI mainframe window ? Pin
CPallini29-Jul-08 0:31
mveCPallini29-Jul-08 0:31 
QuestionHow To Create a Dialog Pin
Dabara28-Jul-08 23:59
Dabara28-Jul-08 23:59 
AnswerRe: How To Create a Dialog Pin
CPallini29-Jul-08 0:27
mveCPallini29-Jul-08 0:27 
GeneralRe: How To Create a Dialog Pin
Dabara29-Jul-08 3:01
Dabara29-Jul-08 3:01 
GeneralRe: How To Create a Dialog Pin
Dabara29-Jul-08 3:09
Dabara29-Jul-08 3:09 
GeneralRe: How To Create a Dialog Pin
Mark Salsbery29-Jul-08 6:40
Mark Salsbery29-Jul-08 6:40 
QuestionHow to update the remote machine registry Pin
pallaka28-Jul-08 23:53
pallaka28-Jul-08 23:53 
AnswerRe: How to update the remote machine registry Pin
bob1697229-Jul-08 6:51
bob1697229-Jul-08 6:51 
QuestionSharePoint Pin
manju#12328-Jul-08 23:01
manju#12328-Jul-08 23:01 
Questionproblem with Gradient scroll Pin
sarat28-Jul-08 22:12
sarat28-Jul-08 22:12 
AnswerRe: problem with Gradient scroll Pin
pallaka28-Jul-08 23:56
pallaka28-Jul-08 23:56 
GeneralRe: problem with Gradient scroll Pin
sarat29-Jul-08 0:07
sarat29-Jul-08 0:07 
QuestionHow to display the strength of the sound recorded from the microphone? Pin
Weiwei.Fang28-Jul-08 21:42
Weiwei.Fang28-Jul-08 21:42 
AnswerRe: How to display the strength of the sound recorded from the microphone? Pin
Mark Salsbery29-Jul-08 6:52
Mark Salsbery29-Jul-08 6:52 
QuestionHow to do... Pin
john563228-Jul-08 21:39
john563228-Jul-08 21:39 
AnswerRe: How to do... Pin
sudhir_Kumar28-Jul-08 21:47
sudhir_Kumar28-Jul-08 21:47 

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.