SmtpMail Class
Note: This API is now obsolete.
Provides properties and methods for sending messages using the Collaboration Data Objects for Windows 2000 (CDOSYS) message component. Recommended alternative: System.Net.Mail.
Assembly: System.Web (in System.Web.dll)
The SmtpMail type exposes the following members.
| Name | Description | |
|---|---|---|
![]() ![]() | SmtpServer | Gets or sets the name of the SMTP relay mail server to use to send e-mail messages. Recommended alternative: System.Net.Mail. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() ![]() | Send(MailMessage) | Sends an e-mail message using arguments supplied in the properties of the MailMessage class. Recommended alternative: System.Net.Mail. |
![]() ![]() | Send(String, String, String, String) | Sends an e-mail message using the specified destination parameters. Recommended alternative: System.Net.Mail. |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
The mail message can be delivered either through the SMTP mail service built into Microsoft Windows 2000 or through an arbitrary SMTP server. Types in the System.Web.Mail namespace can be used from ASP.NET or from any managed application.
If the SmtpServer property is not set, mail is by default queued on a Windows 2000 system, ensuring that the calling program does not block network traffic. If the SmtpMail property is set, the mail is delivered directly to the specified server.
.NET Framework
Supported in: 1.1, 1.0Obsolete (compiler warning) in 4
Obsolete (compiler warning) in 3.5
Obsolete (compiler warning) in 3.5 SP1
Obsolete (compiler warning) in 3.0
Obsolete (compiler warning) in 3.0 SP1
Obsolete (compiler warning) in 3.0 SP2
Obsolete (compiler warning) in 2.0
Obsolete (compiler warning) in 2.0 SP1
Obsolete (compiler warning) in 2.0 SP2
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.



