Ever had a problem, when using @mailsend in form to send mail, that mail gets sent even if field values aren't validated? There might have been @isdocbeingsaved which for some reason didn't work properly. However putting the following formula in to button formula will do the trick.
This will send the mail ONLY when all fields are validated. Did work with 5.06a at least.
@If(@Command([FileSave]);@MailSend(SendTo; ""; "" ; "Subject: Feedback" ;"" ; "Body of the message";""); @Command([FileCloseWindow])