Link to home
Start Free TrialLog in
Avatar of hduncanjr
hduncanjr

asked on

AfxBeginThread

Im using AfxBeginThread in My InitInstance method for a CDialog application. Instead of calling DoModal(I dont want the dialog and am not setting m_pMainWnd = &dlg) Im merely calling
AfxBeginThread() and then WaitForSingleObject(hThread, INFINITE). When I go to TaskManager, I see that its taking 99% of my resources.

Do I need to call GlobalMemoryStatus to get the available virtual and merely use a percentage of it (as the 4th parm to AfxBeginThread) or what do I need to do so as to eliminate this resource hogging?

Help

LostInMemorySpace
ASKER CERTIFIED SOLUTION
Avatar of jkr
jkr
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial