+1 vote

The inline images always got also included as attachments.
How can this be prevented?

by (1.8k points)
edited by

1 Answer

+1 vote
 
Best answer

There are 4 collections that may contain attachments:

  • IMail.Attachments – all attachments (includes Visuals, NonVisuals and Alternatives).
  • IMail.Visuals – visual elements, files that should be displayed to the user, such as images embedded in an HTML email.
  • IMail.NonVisuals – non visual elements, “real” attachments.
  • IMail.Alternatives – alternative content representations, for example ical appointment.

If you want to iterate/get 'real' attachments only use IMail.NonVisuals collection

https://www.limilabs.com/blog/save-all-attachments-to-disk-using-imap

by (297k points)
selected by
...