Allow2010 7 Posted July 5, 2019 Hello, i need to do something like this: $oEmail.Attachments(1).Fields.Item("urn:schemas:mailheader:content-disposition") = "attachment" $oEmail.Attachments(1).Fields.Item("urn:schemas:mailheader:content-transfer-encoding") = "base64" $oEmail.Attachments(1).Fields.Update $oEmail.Attachments(2).Fields.Item("urn:schemas:mailheader:content-disposition") = "attachment" $oEmail.Attachments(2).Fields.Item("urn:schemas:mailheader:content-transfer-encoding") = "base64" $oEmail.Attachments(2).Fields.Update As i do not know how many attachments are needed, i will have to do it for every added attachment. $oEmail.Attachments(X).Fields.Item("urn:schemas:mailheader:content-disposition") = "attachment" Is there a way to do this? Thanks for your ideas and hints 🙂  Share this post Link to post Share on other sites
Jos 2,210 Posted July 5, 2019 For ... Next loop? Jos SciTE4AutoIt3 Full installer Download page  - Beta files    Read before posting   How to post scriptsource   Forum etiquette Forum Rules  Live for the present, Dream of the future, Learn from the past. Share this post Link to post Share on other sites
Allow2010 7 Posted July 5, 2019 (edited) yes, but i can not just use $oEmail.Attachments($i).Fields.Item("urn:schemas:mailheader:content-disposition") = "attachment" as this is some kind of variable name 🙂 At least i think so .-) Edited July 5, 2019 by Allow2010 Share this post Link to post Share on other sites
Allow2010 7 Posted July 5, 2019 Ah, forget it, it does work...i just misinterpreted the syntax, i thought i had to create the varibale name to call it... Share this post Link to post Share on other sites