The MimeParseAddress function is useful for parsing the
email addresses that may be specified in various header fields in
the message. In many cases, the addresses have additional comment
characters which are not part of the address itself. For example,
one common format used is as follows:
"User Name" <user@domain.com>
In this case, the email address is enclosed in angle brackets
and the name outside of the brackets is considered to be a comment
which is not part of the address itself. Another common format
is:
user@domain.com (User Name)
In this case, there is the address followed by a comment which
is enclosed in parenthesis. The MimeParseAddress function
recognizes both formats, and when passed either string, would
return the following address:
user@domain.com
If there was no domain specified in the address, that is just a
user name was specified, then the value the lpszDomain
parameter is added to the address.