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

C / C++ / MFC

 
GeneralRe: How can Check .chm file is open or not? Pin
Le@rner13-Aug-08 20:33
Le@rner13-Aug-08 20:33 
GeneralRe: How can Check .chm file is open or not? Pin
sashoalm13-Aug-08 20:45
sashoalm13-Aug-08 20:45 
GeneralRe: How can Check .chm file is open or not? Pin
Le@rner13-Aug-08 20:54
Le@rner13-Aug-08 20:54 
QuestionUsing Notes C++ API to access Lotus Notes DBs on Visual C++/MFC Pin
afterruins13-Aug-08 19:13
afterruins13-Aug-08 19:13 
AnswerRe: Using Notes C++ API to access Lotus Notes DBs on Visual C++/MFC [modified] Pin
Jijo.Raj13-Aug-08 22:34
Jijo.Raj13-Aug-08 22:34 
QuestionInternet Explorer Socket Programming? [modified] Pin
Ehsan Baghaki13-Aug-08 19:11
Ehsan Baghaki13-Aug-08 19:11 
QuestionHow cab Bold the Caption of Property Pages? Pin
Le@rner13-Aug-08 18:28
Le@rner13-Aug-08 18:28 
AnswerRe: How cab Bold the Caption of Property Pages? Pin
Paresh Chitte13-Aug-08 21:20
Paresh Chitte13-Aug-08 21:20 
GeneralRe: How cab Bold the Caption of Property Pages? Pin
Le@rner13-Aug-08 21:45
Le@rner13-Aug-08 21:45 
GeneralRe: How cab Bold the Caption of Property Pages? Pin
Mark Salsbery14-Aug-08 4:58
Mark Salsbery14-Aug-08 4:58 
QuestionFTPConnection Stalls - Won't Restart or Finish Pin
Stan Bartsch13-Aug-08 15:35
Stan Bartsch13-Aug-08 15:35 
QuestionCan I use _beginthread in a MFC OCX project? Pin
fantasy121513-Aug-08 14:44
fantasy121513-Aug-08 14:44 
AnswerRe: Can I use _beginthread in a MFC OCX project? Pin
Stephen Hewitt13-Aug-08 16:36
Stephen Hewitt13-Aug-08 16:36 
QuestionRe: Can I use _beginthread in a MFC OCX project? Pin
fantasy121513-Aug-08 16:56
fantasy121513-Aug-08 16:56 
AnswerRe: Can I use _beginthread in a MFC OCX project? Pin
Mark Salsbery13-Aug-08 17:02
Mark Salsbery13-Aug-08 17:02 
QuestionHow can I hide/Show Group Box Pin
sabdalla8013-Aug-08 11:02
sabdalla8013-Aug-08 11:02 
AnswerRe: How can I hide/Show Group Box Pin
Joe Woodbury13-Aug-08 11:53
professionalJoe Woodbury13-Aug-08 11:53 
GeneralRe: How can I hide/Show Group Box Pin
Le@rner13-Aug-08 18:30
Le@rner13-Aug-08 18:30 
GeneralRe: How can I hide/Show Group Box Pin
toxcct13-Aug-08 22:28
toxcct13-Aug-08 22:28 
GeneralRe: How can I hide/Show Group Box Pin
David Crow14-Aug-08 3:58
David Crow14-Aug-08 3:58 
AnswerRe: How can I hide/Show Group Box [modified] Pin
toxcct13-Aug-08 22:34
toxcct13-Aug-08 22:34 
GeneralRe: How can I hide/Show Group Box Pin
sabdalla8014-Aug-08 6:25
sabdalla8014-Aug-08 6:25 
QuestionHandle Event from a Class Pin
Sianspheric13-Aug-08 10:05
Sianspheric13-Aug-08 10:05 
QuestionCreating a global mouse hook Pin
JRuthe13-Aug-08 8:34
JRuthe13-Aug-08 8:34 
QuestionThread: Suspending best practice Pin
StevenS_Dev13-Aug-08 7:41
StevenS_Dev13-Aug-08 7:41 
I am just curious as to the best practice for suspending a thread. We have a thread that every once in awhile is required to do something. I am currently using SuspendThread on the CWinThread object. When the thread needs to do work, I Resume the thread. That seems to work well and does not eat up any CPU. But I am just wondering if a better way is to WaitForSingleObject and use an Event to resume the thread.

Using SuspendThread works and is certainly easy to implement, but am just curious which way may provide a better design.

Thanks for the insight.

Note: We were originally ending the thread when it was done with its job, but ran into some other problems. This thread calls into something else which uses OpenMP for multi-threading. When our C++ client thread ended, the OMP threads did not seem to get removed so we kept accumulating OMP threads until we eventually get an error saying too many OMP threads.

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.