MailAddress.Host Property

 

Gets the host portion of the address specified when this instance was created.

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

Public ReadOnly Property Host As String

Property Value

Type: System.String

A String that contains the name of the host computer that accepts e-mail for the User property.

In a typical e-mail address, the host string includes all information following the "@" sign. For example, in "tsmith@contoso.com", the host is "contoso.com".

The following code example displays the destination of an e-mail message.

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

.NET Framework
Available since 2.0
Return to top
Show: