Hi!
I developed a com+ component for sending emails with multiple attachments.The uploaded files are stored on a directory and after the email is send, they are supposed to be deleted.The only problem is that the files aren't deleted.The code looks like this:
What do I do wrong?
I developed a com+ component for sending emails with multiple attachments.The uploaded files are stored on a directory and after the email is send, they are supposed to be deleted.The only problem is that the files aren't deleted.The code looks like this:
Code:
Set oFolder = oFSO.GetFolder(sFolder)
For Each oFile In oFolder.Files
If InStr(oFile.Name, "_" & user) > 0 Then
oMail.AddAttachment oFile.Path
FileSize = Format((FileLen(oFile) / 1024) / 1024)
SumSize = SumSize + FileSize
oFSO.DeleteFile (oFile)
End If
Next
What do I do wrong?