WebApplicationInformation.MachineName Property

 

Gets the application machine name.

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

public string MachineName { get; }

Property Value

Type: System.String

The name of the machine where the application is running.

The following code example shows how to obtain the machine name.

public string GetApplicationMachineName()
{
    // Get the name of the application machine name.
    return (string.Format(
        "Application machine name: {0}",
        ApplicationInformation.MachineName));
}

.NET Framework
Available since 2.0
Return to top
Show: