How can we help?

AxEmail.Constants


In the Auron Email Component, all email constants are grouped together in a separate object called Constants.
First create the constants object before you can actually use the constants:

Set objConstants = CreateObject("AxEmail.Constants")
...
WScript.Echo objConstants.EMAIL_MESSAGE_PRIORITY_HIGHEST
WScript.Echo objConstants.EMAIL_MESSAGE_PRIORITY_HIGH
WScript.Echo objConstants.EMAIL_MESSAGE_PRIORITY_MEDIUM
WScript.Echo objConstants.EMAIL_MESSAGE_PRIORITY_LOW
WScript.Echo objConstants.EMAIL_MESSAGE_PRIORITY_LOWEST
...

IP Version definitions

Constant Value Description
IPVERSION_4 0 Use IP version 4 (default)
IPVERSION_6 1 Use IP version 6
IPVERSION_6_4 2 Use IP version 6, fall back to version 4

Priority definitions

Constant Value Description
EMAIL_MESSAGE_PRIORITY_HIGHEST Highest priority
EMAIL_MESSAGE_PRIORITY_HIGH High priority
EMAIL_MESSAGE_PRIORITY_MEDIUM Normal priority (default)
EMAIL_MESSAGE_PRIORITY_LOW Low priority
EMAIL_MESSAGE_PRIORITY_LOWEST Lowest priority

Encoding definitions

Constant Value Description
EMAIL_MESSAGE_ENCODING_DEFAULT Uses the Operating System’s current codepage
EMAIL_MESSAGE_ENCODING_THAI ISO-8859-11 encoding
EMAIL_MESSAGE_ENCODING_JAPANESE ISO-2022-jp encoding
EMAIL_MESSAGE_ENCODING_CHINESE_SIMP GB2312 encoding
EMAIL_MESSAGE_ENCODING_KOREAN KSC-5601 encoding
EMAIL_MESSAGE_ENCODING_CHINESE_TRAD BIG5 encoding
EMAIL_MESSAGE_ENCODING_CENTRALEUROPE ISO-8859-2 encoding
EMAIL_MESSAGE_ENCODING_RUSSIAN ISO-8859-5 encoding
EMAIL_MESSAGE_ENCODING_WESTERN ISO-8859-1 encoding
EMAIL_MESSAGE_ENCODING_GREEK ISO-8859-7 encoding
EMAIL_MESSAGE_ENCODING_TURKISH ISO-8859-3 encoding
EMAIL_MESSAGE_ENCODING_HEBREW ISO-8859-8 encoding
EMAIL_MESSAGE_ENCODING_ARABIC ISO-8859-6 encoding
EMAIL_MESSAGE_ENCODING_BALTIC ISO-8859-4 encoding
EMAIL_MESSAGE_ENCODING_VIETNAMESE WINDOWS-1258 encoding
EMAIL_MESSAGE_ENCODING_UTF7 UTF-7 encoding
EMAIL_MESSAGE_ENCODING_UTF8 UTF-8 encoding

SMTP Authentication definitions

Constant Value Description
SMTP_AUTH_AUTO 0 Auto detect (default)
SMTP_AUTH_PLAIN 1 AUTH-PLAIN authentication
SMTP_AUTH_LOGIN 2 AUTH-LOGIN authentication
SMTP_AUTH_MD5CRAM 3 AUTH-CRAM-MD5 authentication
SMTP_AUTH_OAUTH2 4 AUTH-OAUTH2 authentication

POP3 Authentication definitions

Constant Value Description
POP3_AUTH_AUTO 0 Auto detect (default)
POP3_AUTH_PLAIN 1 AUTH-PLAIN authentication
POP3_AUTH_APOP 2 APOP authentication
POP3_AUTH_OAUTH2 3 OAUTH2 authentication

IMAP Authentication definitions

Constant Value Description
IMAP_AUTH_AUTO 0 Auto detect (default)
IMAP_AUTH_LOGIN 1 AUTH-LOGIN authentication
IMAP_AUTH_PLAIN 2 AUTH-PLAIN authentication
IMAP_AUTH_OAUTH2 3 OAUTH2 authentication

IMAP Search Key definitions

Constant Value Description
IMAP_SK_ALL ALL All messages
IMAP_SK_ANSWERED ANSWERED Messages with ‘answered’ flag set
IMAP_SK_BCC BCC Containing the specified string in the BCC field
IMAP_SK_BEFORE BEFORE <Date> Before the date specified
IMAP_SK_BODY BODY <String> Containing the specified string in the body of the message
IMAP_SK_CC CC <String> Containing the specified string in the CC field
IMAP_SK_DELETED DELETED Messages with ‘deleted’ flag set
IMAP_SK_DRAFT DRAFT Messages with ‘draft’ flag set
IMAP_SK_FLAGGED FLAGGED Messages with ‘flagged’ flag set
IMAP_SK_FROM FROM <String> Containing the specified string in the FROM field
IMAP_SK_HEADER HEADER <Field> <String> Containing the specified header field with string value. If the string is empty all messages with specified header field are matched.
IMAP_SK_KEYWORD KEYWORD <Flag> Messages with the specified keyword flag set
IMAP_SK_LARGER LARGER <Size> Messages larger than specified number of bytes
IMAP_SK_NEW NEW Messages with ‘new’ flag set
IMAP_SK_NOT NOT <Search key> Messages that don’t match specified search key
IMAP_SK_OLD OLD Messages that do not have the ‘recent’ flag set
IMAP_SK_ON ON <Date> Messages whose date is within the specified date.
IMAP_SK_OR OR <Search key> <Search key> Messages that match either search key
IMAP_SK_RECENT RECENT Messages with ‘recent’ flag set
IMAP_SK_SEEN SEEN Messages with ‘seen’ flag set
IMAP_SK_SENTBEFORE SENTBEFORE <Date> Sent before date
IMAP_SK_SENTON SENTON <Date> Sent on date
IMAP_SK_SENTSINCE SENTSINCE <Date> Sent since date
IMAP_SK_SINCE SINCE <Date> whose date is within or later than date
IMAP_SK_SMALLER SMALLER <Size> Messages smaller than specified number of bytes
IMAP_SK_SUBJECT SUBJECT <String> Containing the specified string in the SUBJECT field
IMAP_SK_TEXT TEXT <String> Containing the specified string in the header or body
IMAP_SK_TO TO <String> Containing the specified string in the TO field
IMAP_SK_UID UID <String> Matching the specified UID. Sequence ranges are allowed
IMAP_SK_UNANSWERED UNANSWERED Messages that do not have the ‘answered’ flag set
IMAP_SK_UNDELETED UNDELETED Messages that do not have the ‘deleted’ flag set
IMAP_SK_UNDRAFT UNDRAFT Messages that do not have the ‘draft’ flag set
IMAP_SK_UNFLAGGED UNFLAGGED Messages that do not have the ‘flagged’ flag set
IMAP_SK_UNKEYWORD UNKEYWORD <Flag> Messages that do not have the specified keyword flag set
IMAP_SK_UNSEEN UNSEEN Messages that do not have the ‘seen’ flag set

IMAP Fetch Macro definitions

Constant Value Description
IMAP_FM_ALL ALL Equivalent to (FLAGS INTERNALDATE RFC822.SIZE ENVELOPE)
IMAP_FM_FAST FAST Equivalent to (FLAGS INTERNALDATE RFC822.SIZE)
IMAP_FM_FULL FULL Equivalent to (FLAGS INTERNALDATE RFC822.SIZE ENVELOPE BODY)

IMAP Fetch Data Items definitions

Constant Value Description
IMAP_FDI_BODY BODY Non-extensible form of BODYSTRUCTURE
IMAP_FDI_BODY BODY [<section>]<<part>> Specific part of message body. Find detailed information in the IMAP RFC
IMAP_FDI_HEADER HEADER Use together with BODY to fetch a part of the body
IMAP_FDI_HEADER_FIELDS HEADER.FIELDS Use together with BODY to fetch a part of the body
IMAP_FDI_HEADER_FIELDS_NOT HEADER.FIELDS_NOT Use together with BODY to fetch a part of the body
IMAP_FDI_MIME MIME Use together with BODY to fetch a part of the body
IMAP_FDI_TEXT TEXT Use together with BODY to fetch a part of the body
IMAP_FDI_BODY_PEEK BODY_PEEK Alternative form of BODY[<section>] that does not set the ‘seen’ flag
IMAP_FDI_BODYSTRUCTURE BODYSTRUCTURE The MIME body structure of the message
IMAP_FDI_ENVELOPE ENVELOPE The envelope structure of the message
IMAP_FDI_FLAGS FLAGS The flags that are set for this message
IMAP_FDI_INTERNALDATE INTERNALDATE The internal date of the message
IMAP_FDI_RFC822 RFC822 Equivalent to BODY[<section>]<<part>>
IMAP_FDI_RFC822_HEADER RFC822.HEADER Equivalent to BODY.PEEK[HEADER] with different return syntax
IMAP_FDI_RFC822_SIZE RFC822.SIZE The size of the message
IMAP_FDI_RFC822_TEXT RFC822.TEXT Equivalent to BODY[TEXT] with different return syntax
IMAP_FDI_UID UID The Unique ID of the message

IMAP Mailbox Flags definitions

Constant Value Description
IMAP_MBX_FLAG_NOINFERIORS \Noinferiors No sub-mailboxes are possible
IMAP_MBX_FLAG_NOSELECT \Noselect It is not possible to use this name as a selectable mailbox
IMAP_MBX_FLAG_MARKED \Marked The mailbox was marked ‘interesting’ by the server
IMAP_MBX_FLAG_UNMARKED \Unmarked The mailbox does not contain addition messages since the last select
IMAP_MBX_FLAG_ALL \All (Special Use) All messages in the users message store
IMAP_MBX_FLAG_ARCHIVE \Archive (Special Use) Used to archive messages
IMAP_MBX_FLAG_DRAFTS \Drafts (Special Use) Save draft messages
IMAP_MBX_FLAG_FLAGGED \Flagged (Special Use) Flagged messages
IMAP_MBX_FLAG_JUNK \Junk (Special Use) Junk messages
IMAP_MBX_FLAG_SENT \Sent (Special Use) A copy of sent messages
IMAP_MBX_FLAG_TRASH \Trash (Special Use) Trash messages
IMAP_MBX_FLAG_HASNOCHILDREN \HasNoChildren (Child Mailbox) This mailbox has no child mailboxes
IMAP_MBX_FLAG_HASCHILDREN \HasChildren (Child Mailbox) This mailbox has child mailboxes

IMAP Mail Flags definitions

Constant Value Description
IMAP_MAIL_FLAG_SEEN \Seen Message has been read
IMAP_MAIL_FLAG_ANSWERED \Answered Message has been answered
IMAP_MAIL_FLAG_FLAGGED \Flagged Message is” flagged” for urgent/special attention
IMAP_MAIL_FLAG_DELETED \Deleted Message is” deleted” for removal by later EXPUNGE
IMAP_MAIL_FLAG_DRAFT \Draft Message has not completed composition (marked as a draft).
IMAP_MAIL_FLAG_RECENT \Recent Message is” recently” arrived in this mailbox.

IMAP Fetch Data Type definitions

Constant Value Description
IMAP_FD_TYPE_INTEGER 1 Integer
IMAP_FD_TYPE_STRING 2 String – String value
IMAP_FD_TYPE_STRING_LITERAL 3 String – String with possible newlines
IMAP_FD_TYPE_LIST 4 List – List of sub-fetch-data items
IMAP_FD_TYPE_ATOM 5 Atom – Keyword or short, simple string value
IMAP_FD_TYPE_NIL 6 NIL – Represents NULL

IMAP Store Option definitions

Constant Value Description
IMAP_STO_SET 1 Set to this exact value
IMAP_STO_ADD 2 Add the given flag to the existing flags
IMAP_STO_REMOVE 3 Remove the given flag from the existing flags
IMAP_STO_SILENT 4 Don’t result in an unsolicited fetch message.

OAuth2 Flow definitions

Constant Value Description
OAUTH2_FLOW_UNDEFINED 0 No flow specified
OAUTH2_FLOW_AUTHCODE 1 Authorization code flow
OAUTH2_FLOW_DEVICECODE 2 Device code flow