Subj : Re: threading problem in dll??? Help needed badly. To : comp.programming.threads From : Joe Seigh Date : Fri Jul 08 2005 07:28 am chuayongquan@hotmail.com wrote: > Ok. I have change all the TryEnterCriticalSection to > EnterCriticalSection but still got error. And i forget to tell you guys > that the stop function is trigger by user (event) one. and the thread > function always running. > You mean an APC? If you're using the TryEnterCriticalSection to avoid deadlock it won't work. EnterCriticalSection should work since it's recursive. Put in a printf statement to make sure your call back function is being invoked. Your program may not be doing any APC enabled waits. -- Joe Seigh When you get lemons, you make lemonade. When you get hardware, you make software. .