 | MailSendMail Method (String, MailAddress, MailAddress, String, String, Boolean, MailPriority, MailAttachmentCollection) |
Send an email via SMTP
Namespace: ToolBooxAssembly: ToolBoox (in ToolBoox.dll) Version: 1.1.0.0 (1.1.0.0)
Syntaxpublic static bool SendMail(
string smtpAddress,
MailAddress from,
MailAddress to,
string title,
string body,
bool isHtml,
MailPriority priority,
MailAttachmentCollection attachments
)
Public Shared Function SendMail (
smtpAddress As String,
from As MailAddress,
to As MailAddress,
title As String,
body As String,
isHtml As Boolean,
priority As MailPriority,
attachments As MailAttachmentCollection
) As Boolean
Parameters
- smtpAddress
- Type: SystemString
Smtp address - from
- Type: System.Net.MailMailAddress
From mail address - to
- Type: System.Net.MailMailAddress
To mail address - title
- Type: SystemString
Subject of the email - body
- Type: SystemString
Body of mail's message - isHtml
- Type: SystemBoolean
Format of the body - priority
- Type: System.Net.MailMailPriority
Priority of the email - attachments
- Type: ToolBooxMailAttachmentCollection
Collection of attachments (null for none)
Return Value
Type:
BooleanTrue if messagge sended successfully; false otherwise
See Also