PDA

Click to See Complete Forum and Search --> : Thread Enumeration


CoreyS
Feb 14th, 2001, 10:56 AM
Hey Everyone...

Does anyone know how to enumerate and get the handle to a thread and terminate it?

For Example, I have a process that has 3 threads associated with it. I would like to enumerate the threads and end each one manually and indivdually.

Any help would be great!

Corey

Alfred
Feb 14th, 2001, 02:10 PM
I only known a API call to get the thread ID from a window handle that was create by the thread:

Declare Function GetWindowThreadProcessId Lib "user32" (ByVal hwnd As Long, lpdwProcessId As Long) As Long

lpdnProcessId can be NULL. Maybe this can be a starting point for your search.