Run Action Icon

Send E-mail Action

Declaration

<AMSMTPMAIL SUBJECT="text" HTML="yes/no" ATTACH="text" TO="text" CC="text" BCC="text" SERVER="text" PORT="number" FROM="text" REPLYTO="text" PROXYTYPE="text [options]" PROXYSERVER="text" PROXYPORT="number" PROXYUSERNAME="text" PROXYPASSWORD="text">text</AMSMTPMAIL>

 

See Also

POP3 E-mail, Dial Up, HTTP Download, HTTP Post, Open Web Page

Description

Sends an email message using the SMTP protocol. SMTP is the standard protocol for sending messages on the Internet. NOTE: AOL and MSN do not support SMTP. Most other ISPs, however, do support SMTP.

Practical Usage

Used to send an email message plain text or HTML formatted, with or without attachments, using the Internet Standard SMTP Protocol. Frequently system administrators will choose to use this action to perform system notifications or conveniently package data retrieved from any other source such as databases or web sites.

Parameters

General Tab

To
Text, Required
MARKUP: TO="webmaster@unisyn.com"

Specifies the recipient(s) of the message. Multiple recipients must be separated by semi-colons (;).

The recipient parameter can be in any of the following formats:

a) webmaster@unisyn.com
b) Unisyn Software Webmaster <webmaster@unisyn.com>
c) webmaster@unisyn.com;sales@unisyn.com

CC
Text, Optional - Default (blank)
MARKUP: CC="webmaster@unisyn.com"

Specifies addresses that the message should be sent "carbon-copies" to. Multiple recipients must be separated by semi-colons (;).

The CC parameter can be in any of the following formats:

a) webmaster@unisyn.com
b) Unisyn Software Webmaster <webmaster@unisyn.com>
c) webmaster@unisyn.com;sales@unisyn.com

Subject
Text, Optional - Default (blank)
MARKUP: SUBJECT="This is a test message from AutoMate 5"

Specifies the subject of the message.

Body
Text, Optional - Default (blank)
MARKUP: >"This is a test message from AutoMate 5"</SMTPMAIL>

Specifies the body of the message. If the "Is HTML" [HTML] parameter is set to YES, this section should be properly formatted HTML, otherwise this parameter should contain a plain text version of the message.

Is HTML
YES/NO, Optional - Default NO
MARKUP: HTML="YES"

Specifies that the body of the message is formatted HTML and should be displayed by the recipients mail client as such (if supported). Causes the following mail header to be inserted: Content-Type: multipart; boundary="xxxxx"

Use file contents as body
Text, Optional - Default (blank)
MARKUP: BODYFILE="c:\foldername\body.txt"

Specifies that the body of the message should be obtained from the specified text file. When set to YES causes the Body of the message to be ignored.

Server
Text, Optional - Default (blank, uses default server for the AutoMate installation)
MARKUP: SERVER="mail.server.com"

Specifies the SMTP server that should be used to send the message. If nothing is specified, AutoMate will attempt to use the default mail settings for the current AutoMate Installation as specified in the Task Administrator Preferences.

Port
Number, Optional - Default (blank, uses default server for the AutoMate installation)
MARKUP: PORT="3333"

Specifies the port that should be used when connecting to the SMTP server. Most SMTP servers run on port 25.  If nothing is specified, AutoMate will attempt to use the default mail settings for the current AutoMate Installation as specified in the Task Administrator Preferences.

From
Text, Optional - Default (blank but usually required by most servers)
MARKUP: <SENDER SERVER="mail.server.com" FROM="me@unisyn.com" REPLYTO="meinstead@unisyn.com

Specifies the address information about who the mail should be from.

The FROM parameter can be in any of the following formats:

a) webmaster@unisyn.com
b) Unisyn Software Webmaster <webmaster@unisyn.com>

Reply to
Text, Optional - Default (blank)
MARKUP: <SENDER SERVER="mail.server.com" FROM="me@unisyn.com" REPLYTO="meinstead@unisyn.com

Specifies the address information about who the mail should be from.

The FROM parameter can be in any of the following formats:

a) webmaster@unisyn.com
b) Unisyn Software Webmaster <webmaster@unisyn.com>

BCC
Text, Optional - Default (blank)
MARKUP: BCC="webmaster@unisyn.com"

Specifies addresses that the message should be sent "blind-carbon-copies" to. Use of the "blind-carbon-copies" hides the addresses from the target users. Multiple recipients must be separated by semi-colons (;).

The BCC parameter can be in any of the following formats:

a) webmaster@unisyn.com
b) Unisyn Software Webmaster <webmaster@unisyn.com>
c) webmaster@unisyn.com;sales@unisyn.com

Attach
Text, Optional - Default (blank)
MARKUP: ATTACH="c:\foldername\file1toattach.zip;c:\foldername\optionalfile2toattach.zip;"

Specifies file(s) to attach to the email message. Files will be MIME encoded automatically. In Markup mode, multiple file attachments must be separated by semi-colons (;), in visual mode simply add the files to the list.

Proxy Tab

Proxy Type
Text [options], Optional - Default (none)
MARKUP: PROXYTYPE="Socks5"

Specifies proxy protocol that should be used.  If you are unsure of the value to use in this parameter, contact your network administrator.

Available Options Are:

System Default (default, recommended) - The settings specified in the Task Administrator preferences are used.
None - Explicitly instructs the action not to use a proxy server regardless of the system default
Socks 4 - Instructs the action to go through a Socks 4 compliant server
Socks 4a - Instructs the action to go through a Socks 4a compliant server
Socks 5 - Instructs the action to go through a Socks 5 compliant server

Note:  To create the most portable tasks it is best to specify "system default" and specify proxy settings in the Preferences of the Task Administrator (Proxy Tab).  By proceeding this way, tasks created in one environment that may have a proxy server will be portable to others that do not - and vice-versa.

Proxy Port
Number, Optional - Default 1028
MARKUP: PROXYPORT="3000"

Specifies the port that should be used to connect to the proxy server. Most proxy servers operate on port 1028 (the default) however the proxy server can be customized to operate on other ports

Proxy Host
Text, Optional - Default (blank)
MARKUP: PROXYSERVER="proxy.host.com"

Specifies the hostname (server.domain.com) or IP address (xxx.xxx.xxx.xxx) of the proxy server.

User Name (Proxy)
Text, Optional - Default (none)
MARKUP: PROXYUSERNAME="username"

Specifies the username that should be used to authenticate when connecting through the proxy server. This option is only valid when Socks 5 is specified in the Proxy type as it is the only version that supports authentication.

Password (Proxy)
Text, Optional - Default (none)
MARKUP: PROXYPASSWORD="encrypted"

Specifies the password that should be used to authenticate when connecting through the proxy server. When the step is created using the Task Builder it is written to the task encrypted. This option is only valid when Socks 5 is specified in the Proxy type as it is the only version that supports authentication.

Notes

Standard Error Handling Options
This action also includes the standard "Error Causes" and "On Error" failure handling options/tabs

More on Error Handling Options

Variables and Expressions
All text fields allow the use of expressions by surrounding the expression in percentage signs (example: %MYVARIABLE%, %Left('Text',2)%). To help construct these expressions, a popup expression builder is available in all these fields by pressing F2.
More on variables...

More on expressions...

More on the expression builder...

Example

<AMSMTPMAIL SUBJECT="This is a test of the email action of AutoMate 5" TO="webmaster@unisyn.com" SERVER="mail.server.com" FROM="me@unisyn.com">Hello this is the body of my message

</AMSMTPMAIL>