Internet Address List Conversion (Internet Address List to Mail Address Collection)
Explicit cast to convert a InternetAddressList to a
MailAddressCollection.
Definition
Namespace: MimeKit
Assembly: MimeKit.Core (in MimeKit.Core.dll) Version: 5.0.0
The equivalent MailAddressCollection.
Assembly: MimeKit.Core (in MimeKit.Core.dll) Version: 5.0.0
C#
public static explicit operator MailAddressCollection? (
InternetAddressList? addresses
)Parameters
- addresses InternetAddressList
- The addresses.
Return Value
MailAddressCollectionThe equivalent MailAddressCollection.
Remarks
Casts a InternetAddressList to a MailAddressCollection
in cases where you might want to make use of the System.Net.Mail APIs.
Exceptions
| InvalidCastException | addresses contains one or more group addresses and cannot be converted. |