I am sending a file as an attachment:
// Create the file attachment for this e-mail message. Attachment data = new Attachment(filePa
Disposing your message will fix this for you. Try calling Dispose on your message before moving the file, like so:
message
Dispose
message.Dispose(); File.Move(...)
When disposing MailMessage, all locks and resources are released.