The /MAIL command is used for automated message creation using a
template, text file and/or set of attached files for a specific
destination address. This command is extremely useful for
applications that need to send e-mail messages without having to do
the additional work involved in the implementation of the various
Internet e-mail standards.
Syntax
/MAIL[parameter1[;parameter2[;parameter3[...]]]
Parameters
USER=value or U=value
|
value is the name of the source account. If no FOLDER parameter
is specified, the target folder will be the Inbox of the given
account.
|
PASSWORD=value or P=value
|
value is the password which will unlock the account if it is
needed.
|
FOLDER=value or F=value
|
value is the target folder's pathname. If the pathname does not
include an account name, The Bat! will search all accounts for a
folder with a matching name; the first folder found will be used as
the target folder. If the specified folder is not found, the Outbox
folder of the target account is used.
|
TEMPLATE=value or T=value
|
value is the pathname of the file which contains the template
that will be used for the creation of the message. By default, it
is the standard template of the target folder or the target
account.
|
TO=value
|
value specifies the primary addressee of the message. You can
add additional addressees using template macros %TO, %CC, %BCC.
|
SUBJECT=value or S=value
|
value specifies the subject of the message. It is also possible
to define the message subject in the template using %SUBJECT
macros.
|
TEXT=value or CONTENTS=value or C=value
|
value is the pathname of a plain text file which contains the
text of the message. It is also possible to include a text file
into a message using the %PUT macro in the template.
|
ATTACH=value or FILE=value or A=value
|
value is the pathname of the file which will be attached to the
message. It is also possible to use %ATTACHFILE macros in the
template.
|
SEND
|
if this parameter is used, the created message will be sent out
as soon as it has been created.
|
QUEUE
|
if this parameter is used, the created message will be queued in
the Outbox once it is created.
|
EDIT
|
if this parameter is used, The Bat! opens the editor with the
message created using the parameters from above
|
Examples
/MAILU=MyAccount;TO=some@address.com;S=Test;TEXT=C:\TESTs\TEST.MSG
/MAILF=\\MyAccount\Test;TO=some@address.com
Note: To separate
parameters, use semicolons (";" characters). Do not put spaces
between parameters when using the /EXPORT command from the
command line because a space-separated mask will be interpreted as
the next command line parameter and will not be processed as
intended.
Note: If a parameter
value contains space characters, enclose it in quotation marks. If
a value contains quotation marks, you should use single quotes (" '
" characters).
|