Make sure that God is the one who shut the door. If God really did shut the door then stop banging on it. Otherwise, Matt 7 "Ask and it will be given to you; seek and you will find; knock and the door will be opened to you.
I am determined to be cheerful and happy in whatever situation I may find myself. For I have learned that the greater part of our misery or unhappiness is determined not by our circumstance but by our disposition.