I am using a threading architecture in my ASP.NET web application. In this application, I have maintained a global application variable that i want to access in a Thread.
How can i get Application state in a Thread?
I am using a threading architecture in my ASP.NET web application. In this application, I have maintained a global application variable that i want to access in a Thread.
How can i get Application state in a Thread?
HttpContext.Current
will be null in subsequent threads. See this question for details:
The cross-thread usage of "HttpContext.Current" property and related things
However, you could just pass System.Web.HttpContext
to the threads and access Current
from each thread.