HttpWebResponse.Server Property

 

Gets the name of the server that sent the response.

Namespace:   System.Net
Assembly:  System (in System.dll)

member Server : string with get

Property Value

Type: System.String

A string that contains the name of the server that sent the response.

Exception Condition
ObjectDisposedException

The current instance has been disposed.

The Server property contains the value of the Server header returned with the response.

The following example uses the Server property to display the Web server's name to the console.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 1.1
Return to top
Show: