WebProcessInformation.ProcessID Property

 

Gets the process identifier.

Namespace:   System.Web.Management
Assembly:  System.Web (in System.Web.dll)

public int ProcessID { get; }

Property Value

Type: System.Int32

The process identifier.

This is the identifier of the worker process that hosts ASP.NET.

The following example shows how to obtain the process identifier.

public string GetProcessId()
{
    // Get the process identifier.
    return (string.Format(
        "Process Id: {0}", 
        ProcessInformation.ProcessID.ToString()));
}

.NET Framework
Available since 2.0
Return to top
Show: