Solved

AfxBeginThread

Posted on 2004-10-12
3
355 Views
Last Modified: 2013-12-03
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
0
Comment
Question by:hduncanjr
3 Comments
 
LVL 86

Accepted Solution

by:
jkr earned 500 total points
Comment Utility
No, there's no need to specify a stack size. What is your thread actually doing?
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

This article shows how to make a Windows 7 gadget that accepts files dropped from the Windows Explorer.  It also illustrates how to give your gadget a non-rectangular shape and how to add some nifty visual effects to text displayed in a your gadget.…
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now