Thread count/ identity ?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • fniles

    #1

    Thread count/ identity ?

    I am using VB.NET 2003 and a threadpool.
    In a threadpool, is there any way to find out the thread count or some kind
    of thread identity ?
    Thank you.

    Dim clsEachMessage As New EachMessage
    ThreadPool.Queu eUserWorkItem(N ew WaitCallback(Ad dressOf
    clsEachMessage. ProcessMessage) )

    Public Class EachMessage
    Public Sub ProcessMessage( ByVal stateInfo As Object)
    -->HERE I would like to find out the thread count or some kind of thread
    identity of this particular thread


  • sloan

    #2
    Re: Thread count/ identity ?






    static void ThreadMethod()
    {
    Console.WriteLi ne("ThreadOne, executing ThreadMethod, " +
    "is {0}from the thread pool.",
    Thread.CurrentT hread.IsThreadP oolThread ? "" : "not ");
    }


    Will that work with the Pool?


    "fniles" <fniles@pfmail. comwrote in message
    news:OOW3FnJmHH A.1624@TK2MSFTN GP02.phx.gbl...
    I am using VB.NET 2003 and a threadpool.
    In a threadpool, is there any way to find out the thread count or some
    kind
    of thread identity ?
    Thank you.
    >
    Dim clsEachMessage As New EachMessage
    ThreadPool.Queu eUserWorkItem(N ew WaitCallback(Ad dressOf
    clsEachMessage. ProcessMessage) )
    >
    Public Class EachMessage
    Public Sub ProcessMessage( ByVal stateInfo As Object)
    -->HERE I would like to find out the thread count or some kind of thread
    identity of this particular thread
    >
    >

    Comment

    Working...