On 9/23/05, Allan N. <[EMAIL PROTECTED]> wrote:
> in my naive attempt to spin off 6 threads and then wait for them to finish
> before filling a grid I got the
> "WaitAll for multiple handles on an STA thread is not supported" message
> flashing in my eyes.

I too am surprised the WaitAll option is not available to the standard
environment.

> checking the documentation was perhaps the best I could have done before
> going this way :).
>
> what else could I use here instead of WaitAll ? using ManualResetEvent
> [curThread].WaitOne and then looping seems rather tedious...

The SDK documentation's fully manged Monitor example uses the
Interlocked class to manually count the completed threads:

ms-help://MS.NETFrameworkSDKv1.1/cpguidenf/html/cpconmonitor.htm

That'd be:

http://msdn.microsoft.com/library/en-us/cpguide/html/cpconMonitor.asp

Regards,
Mark Hurd, B.Sc.(Ma.)(Hons.)

===================================
This list is hosted by DevelopMentorĀ®  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

Reply via email to