When and which event should be used when you want delete a file after being attached to an email and the email has been successfully sent?
I’m getting an error in deleting saying that the file is still being used after the email has been sent successfully.
You must ensure you’ve
Disposed your MailMessage – once that’s done the file you attached can be deleted.