Hello Eric,
My apologies, it was rather late when I posted the code last night. This is much cleaner. (presuming you want to show the same document each time, and not a new one)
It just makes sure that the current document window is hidden, can only be shown once, and can be closed and re-shown
Let me know if you have any questions
Richard