No startup journey would be complete without an emotional meltdown -- the kind that leaves grown men sitting alone in the dark, drowning their sorrows in Ben & Jerry’s while Adele blares in the background. While the comfort food may change, rock bottom always feels the same.

For me, it came on the heels of a major win. Just before I completed my undergraduate degree, a company I founded had just been acquired, and I was working for the new parent company.

Related: 3 Ways to Wring at Least Some ROI From Failure

I’d convinced my 12-person team to move to Phoenix with me. Many had to leave their homes, schools, significant others and higher-paying jobs, but I took their sacrifices as a vote of confidence in our team and what we were creating. Nine months later, the deal fell apart, and we lost the company we had built. I was devastated. It took three months of emotional detox before I could think clearly about the future.

After the initial tidal wave of emotion had passed, I invited my 12 former teammates to my house. We ordered food, hung out and talked about what we wanted to do. We were all in agreement: We didn’t want to pack up and move back home.

After hammering out what motivated and inspired us, we developed an action plan to find a new venture. That discussion led to us finding our new home at Coplex.

Major losses force entrepreneurs to make hard decisions. These decisions almost always turn your life to a new chapter where the stakes are higher and the wins are bigger. To navigate this, I use an exercise that helps me discharge the emotion from the tough situation, review the facts, learn some lessons and make a good decision on how to move forward.

To complete the exercise yourself, you’ll need a piece of paper divided into three sections horizontally (hamburger style, not hotdog style).

1. Go through an emotional detox.

You’re a human, not a robot, so deal with your emotions first. Relive the situation -- emotions and all. Monitor how you’re feeling at different points of the experience. Think about the overall state of mind this puts you in.

Related: How These Entrepreneurs Failed Their Way to Millions

2. Write down the facts.

Now, let’s handle the first section of your paper. Describe your situation the way a journalist would. Report the facts with no emotional charge. Write what happened and why -- avoiding adverbs and loaded language. No need to think about what your decision will be at this point, just explain what’s happened so far.

3. Write down the lessons you learned.

Our brains are wired to dwell on negative experiences, so why not put that mental energy to use? Even in the worst situations, there are always lessons to be gleaned. Jot these down in the second section. Identify small changes you can make to avoid similar situations. It might seem elementary, but it gives you a sense of control, which psychologists have identified as the number-one contributor to happiness.

4. Create a plan based on facts.

Now, you’re in a good state of mind to develop an action plan. First, jot down some options in the third section. Then, select your plan and define it step by step. Next, read it to ensure each item is driven by facts from the second step.

I’ve used this process several times, and it’s helped transform emotionally-charged situations into opportunities for growth. It’s also helped me find peace in, and even gratitude for, the dark experiences that brought me to a new level of potential.

When founding Coplex from the ashes of my previous company, I realized we had everything we needed for our next venture right at our fingertips. We had a dedicated, collaborative team and a wealth of industry experience as a startup and as a part of a larger corporation. We were able to build a new company around the resources and knowledge we already possessed.

When something goes wrong, it’s easy to let emotions run the show. But don’t drown in ice cream -- grab a piece of paper and get it all out. Once you do, you can examine the situation objectively, reframe it as a lesson and allow facts to guide your choices.

Related: Why Overcoming Failure Is the First Step Toward Success