I forgot to mention that the code works as-is without doing anything where the TODO comment is in the code I posted. Since I just whipped this up, I left a note to the reader that you'd probably want to do a proper DuplicateHandle to bump up the ref count on the underlying thread handle once you've extracted it out of the Thread class to prevent it from becoming invalidated while you're hanging onto it - then clean it up later using CloseHandle. But you probably won't need to do that just to tinker with this (I didn't). Of course, this code is so tightly coupled to the current build of the runtime that you'd probably want to do more than that - like assert you're working on the right build of the CLR :-)
-Mike http://staff.develop.com/woodring http://www.develop.com/devresources ----- Original Message ----- From: "Mike Woodring" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, April 20, 2002 1:28 AM Subject: Re: [DOTNET] Waiting for multiple Threads > I did a little poking around in the debugger and came up with some "working > code" that you might want to take and run with. Obviously, solutions like > this are highly coupled to the current build of the runtime, so always > remember that you get what you pay for; and that this is free code :-) > You can read messages from the DOTNET archive, unsubscribe from DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.