0
首先我用這個代碼刪除所有附件在Outlook如何刪除在Outlook中的所有附件
For i = 1 To oMail.Attachments.Count
oMail.Attachments.Remove(i)
Next
我有4個附件刪除它,但我檢查oMail.Attachments.Count
它顯示2
我搜索後在堆論壇這個代碼
For Each a As outlook.Attachment In oMail.Attachments
a.Delete()
Next
它刪除1 & 3附着但不刪除2 & 4附着
可能的重複[對於每個循環:在通過Outlook郵箱循環刪除項目時會跳過一些項目](http://stackoverflow.com/questions/10725068/for-each-loop-some-items-get-skipped - 當 - 循環 - 通觀郵箱到德) – niton