Sometimes, no matter what you do, things can go terribly wrong. When that happens, you have a chance to either be dragged down by the weight of the disaster, or fight your way through it.

If you choose to do the latter, it's possible for something terrible to turn into a valuable experience. You may not think you'll ever look back on something bad happening and see the good in it, but it can happen.

Of course, that doesn't mean you should wish for disaster, but our panel of Motley Fool writers have all been through some terrible situations and come out of it better off in the long term. We don't wish a workplace disaster on anyone, but we're happy to share how we benefited from living through one.

A blackboard says are you ready?

You can't prepare for every situation, but you can control how you react when something goes wrong. Image source: Getty Images.

It pays to be calm when everyone else is freaking out

Maurie Backman: When I worked for an online marketing company, we had a day when the phones and internet all went out and stayed down for hours. Clearly, this was not ideal, as it instantly killed everyone's productivity. But while my colleagues were losing their cool and moaning about how far behind they were going to fall as a result of this outage, I stayed calm and found other ways to productively occupy my time. And that's something my boss noticed and appreciated.

Rather than throw my hands up in the air, I decided to take the opportunity to do some work offline. This is something that many of my colleagues could've done as well, but rather than take a step back and realize the day didn't have to be totally lost, they spent their time worrying about catching up. Now to be fair, my team was facing a major deadline later that week, so it was a truly bad time for our systems to fail, but because I remained calm, I was able to salvage much of the day.

Of course, the funny thing is that the company could've just decided to send everyone home and let them work from their respective residences rather than make several hundred employees sit there twiddling their thumbs. Why that never occurred to anyone is beyond me, but I'm guessing most folks were so preoccupied by the technical difficulties we were facing that they never stopped to just think and come up with a logical temporary fix.

By the end of the day, the company was back up and running, and my team managed to pull together for our big deadline. But let this be a lesson: It's easier to flip out than to take a deep breath and figure out a Plan B. But if you take the latter approach, you'll likely come out ahead in the face of disaster.

You never know who sees how you respond to difficulty

Jason Hall: In 2002, I was a manager for now-defunct Circuit City, and everything changed overnight early that year, when the company made the decision to move its entire sales staff from commission to an hourly rate. That was only part of the strategy; the company also chose to eliminate the 20% highest-earning salespeople at the same time. 

It was a disaster. We lost some of the most motivated and hardest-working employees in the building and saw the demoralization of many who were left -- and a complete loss of focus on taking care of customers. The months that followed were incredibly challenging, as we took steps to rebuild staffing, try to retain the best-remaining employees, and deal with the attrition caused by the change in pay structure and the loss of incentive. 

In these situations, the best -- yet often hardest -- thing to do is put your head down and do the work. I wasn't in a position to "fight city hall" on this major change in strategy, so I did my job: worked hard to implement the new strategy. It paid off in an unexpected way. when I was recruited by one of my customers. He saw the result of my hard work in the way my staff and I took care of him when he shopped in my store. 

I could've become disgruntled in my frustration, but instead, I did the best I could with what I was given, and it worked out in a surprising way with a new opportunity at another company. 

Find a way through

Daniel B. Kline: For two years in the mid-2000s, I ran a giant toy, hobby, and model train store. We were a destination partly because we devoted over 5,000 square feet to multiple indoor model train layouts. Those were created by clubs in the store, and they served to draw in customers locally and tourists who then got exposed to our huge selection of model train items.

So, as you might imagine, we were pretty excited when the national model train conference was not only coming to our area, but bringing busloads full of enthusiasts on a trip to our store. This was an important event because we had hundreds of thousands of dollars worth of collectible inventory. These were trains that a collector might buy but our normal clientele would almost certainly not.

On the day the buses would be arriving -- a day we expected to do tens of thousands of dollars in sales of otherwise mostly dead inventory -- a car hit a transformer on our street. It knocked our power out with no hopes of getting it back.

My initial reaction was heartbreak and that we would have to cancel. Instead, after we took a few moments to mourn, I sent staffers out to buy every flashlight they could find. As the buses arrived we sent groups of visitors to see the train layouts (which could not be operated) and to let them talk with the people who built them.

We, of course, also showed off out merchandise, and while sales were well below expectations, they were still significant. Using flashlights and running credit cards on those old machines that made an imprint of the card, we did the best we could in a bad situation.

It was still a disaster, but it could have been much worse. We also got a lot of thank-yous from the visitors to the store who appreciated the effort and understood that there was nothing we could have done to prevent the situation from happening.