Mac OSX Mail Closes main window after hitting send Recently every time I compose an email, when I hit send not only does the mail compose window disappear (as expected) so does the main mail window... and then I have to click the dock icon to bring it back!  Ideas on why this has just started happening?
When you check the logs in Console, you may find it convenient and more informative if you first select All Messages in the left column, then use the Filter blank/box in the upper right of that window and enter "Mail".

This should produce a list of all log entries relating to Mail only.  It may not pick up everything that is involved in creating the actions you see in Mail, but it will find most of them, and could help in giving a clue to the problem.  It does get rid of all the entries that are unrelated to the problem.

When looking at these filtered messages, try to remember the last changes you made to the system.  Don't limit your thinking to changes in Mail, but think about all apps and add ons you installed. It's the unintended (and unknown) consequences that often cause such problems.  They sometimes don't reveal themselves until days later. 

A couple of other things to do that can often correct weird behavior, especially in apps native to the OS:

Safe Boot, then immediately reboot normally without logging in.

Reinstall the OS Combo update.

Neither of these is a sure cure, but used in the above order, will often fix this kind of problem.  About the only thing you learn from the exercise is that it can often cure the problem, and you still don't know what was wrong.

Whatever you do, be methodical in your approach.  Try only one "fix" at a time, and then test for problems.  This is the easiest way to learn and improved your problem-solving skills.