opflags (Num) specifies various operation flags, using the sum of one or more of the following:
Symbol |
Value |
Type |
Description |
---|---|---|---|
EMF_NORMAL |
0 |
B,2 |
normal operation |
EMF_LEAVEOPEN |
1 |
B,2 |
don't close session |
EMF_ALREADYOPEN |
2 |
B,2 |
don't open; (already open) |
EMF_OPENONLY |
4 |
B,2 |
open only; ignore all but SERVER & HOST |
EMF_CLOSEONLY |
8 |
B,2 |
close only |
EMF_HDRCAT |
16 |
B,2 |
concatenate HEADER+BODY (no CRLF) |
EMF_HTMLBODY |
32 |
B,2 |
BODY contains <HTML> |
EMF_MIMEBODY |
64 |
|
BODY is a self-contained MIME part |
EMF_TLS |
1024 |
|
Use SSL/TLS for SMTP connection |
EMF_STARTTLS |
2048 |
|
Use STARTTLS (start with unencrypted connection, then elevate to TLS with the STARTTLS SMTP command) |
Definition file: emailx.def |
Note that in most cases you can get by with EMF_NORMAL. The next four flags (EMF_LEAVEOPEN, EMF_ALREADYOPEN, EMF_OPENONLY, and EMF_CLOSEONLY) are only of interest if you are sending a lot of emails in a batch and want to eliminate the overhead of having to open and close the connection with the SMTP server for each message. EMF_HDRCAT is only used when you want to include email header items in both the header and body parameters. And EMF_HTMLBODY is only recommended when you have used your own HTML formatting within the body of your message.