B4X Requires Chilkat v11.0.0+
B4X
Read individual messages in a MIME digest
See more Email Object Examples
Use a saved multipart/digest message. NumDigests and GetDigestEmail expose each enclosed message as an Email object. Inspect its own sender and subject instead of assuming all entries share the wrapper’s metadata.
Chilkat B4X Downloads
Dim success As Boolean = False
' Assumes Chilkat is unlocked. See Global Unlock Sample.
Dim email As ChilkatEmail
email.Initialize
success = email.LoadEml("digest.eml")
If success <> True Then
Log(email.LastErrorText)
Return
End If
Log("Digest entries: " & email.NumDigests)
Dim item As ChilkatEmail
item.Initialize
Dim i As Int = 0
Do While (i < email.NumDigests)
success = email.GetDigestEmail(i, item)
If success <> True Then
Log(email.LastErrorText)
Return
End If
Log(i & " " & item.FromAddress & " " & item.Subject)
i = i + 1
Loop