A guide to all of the properties that ASPMail provides on our NT Servers.
The message body text. To clear the text once you have set it use the ClearBodyText Method.
Example:
Mailer.BodyText = "Your order for 15 widgets has been processed"
The character set. By default the char set is US Ascii
Valid values:
Example:
Mailer.CharSet = 2
The ConfirmReading flag. If this is set to true AND the recipients email program supports
this feature (and it is enabled) the recipients email program will send a notice back to the FromAddress confirming that this email has been read.
Example:
Mailer.ConfirmRead = true
The ContentType property allows you to set the ContentType header of the message's BodyText. If, for example, you wanted to send HTML as the messages's body, you could set ContentType = "text/html" and EMail programs that support HTML content could properly display the HTML text.
Note: The ContentType property is ignored if you have file attachments.
Example:
Mailer.ContentType = "text/html"
If you wish to use a character set besides the included types you can set CustomCharSet to a character set string.
Example:
Mailer.CustomCharSet =
"ISO-2022" or
Mailer.CustomCharSet = "big5"
AspMail will, by default, create a Date/Time header for your local system using GMT. If you would like to override the date/time calculation set the DateTime property to a valid date/time string in the format defined by RFC 822 & RFC 1123. Example:
Mailer.DateTime = "Fri, 02 May 1997 10:53:49 -0500"
The encoding type for attachments. The default setting is MIME.
Valid values:
Example:
Mailer.Encoding = 1
The message originator’s name.
Example:
Mailer.FromName = "Joe’s Widget Shop"
Tthe message originator’s email address.
Example:
Mailer.FromAddress = "joe@widgets.com"
Sets the Organization header in the message.
Example:
Mailer.Organization = "Your Company Name"
Sets the message priority. Priorities are 1-5 and are reflected in the X-Priority
Valid values:
Example:
Mailer.Priority = 1
The remote SMTP host that the message will be sent through. This is typically an SMTP server located at your local ISP or it could be an internal SMTP server on your companies premises. Up to 3 server addresses can be specified, seperated by a semicolon. If the primary server is down the component will attempt to send the mail using the seconary server and so on.
Example:
Mailer.RemoteHost =
"mailhost.myisp.net"
or
Mailer.RemoteHost = "mailhost.myisp.net; mailhost.myotherisp.net"
The ReplyTo property allows you to specify a different email address that replies should be sent to. By default mail programs should use the Reply-To: header for responses if this header is specified.
The Response property returns any error messages that may occur.
The ReturnReceipt flag. If this is set to true AND the recipients SMTP server supports this feature (and it is enabled) the recipients SMTP server will send a notice back to the FromAddress confirming that this email has been delivered.
Example:
Mailer.ReturnReceipt = false
If you need to debug the session give a log file name here. Make sure the IUSR_XYZ IIS user has security that allows the component to write to this file. Warning: Do not use this setting in situations where multiple users can access this component at the same time. This is for single user debugging ONLY!
Example:
Mailer.SMTPLog = "c:\smtplog.txt"
The message subject.
Example:
Mailer.Subject = "Stock split announced!"
The SuppressMsgBody property is true by default and is used in conjuction with the SMTPLog property. When SMTPLog is set to a file and SuppressMsgBody is true the log file receives a copy of the message text. If SuppressMsgBody is false the message text is not sent to the log.
Timeout is the maximum time that AspMail should wait for a response from the remote server. The default is 30 seconds.
Example:
Mailer.Timeout = 15
The urgent flag sets the X-Urgent header in the outgoing message. Not all mail readers support this flag.
Example:
Mailer.Urgent = true
MS-Mail priority headers, by default, are sent in addition to the standard SMTP priority headers. You can turn MS-Mail headers off with this property
Example:
Mailer.UseMSMailHeaders = false
Gets the internal component version number.
Example:
Response.Write "Component Version: " & Mailer.Version
The WordWrap property is off by default. Setting WordWrap to true causes the message body to wordwrap at the position specified by the WordWrapLen property.
The WordWrapLen property is set to 70 by default. You can modify the position that wordwrap occurs by changing this value.