Hi, Eric!
I know exactly what you mean. I come from a country where armed robbery is a common occurrence - I'm not exaggerating, If you haven't been mugged at gun point in a year, you consider yourself lucky - But a robbery is not the only bad experience that can make it difficult to keep putting down words.
A fight with a family member, a hard week at work, or even taking a break from your usual writing schedule can end you up with big difficulties to keep writing.
I hate to call it "writer's block", I think we give the situation too much power by ascribing to it its own name. But however you call it, not being able to sit down and write what you want can almost always be reduced to a lack of focus; you need your mind in a place - that oh so sought after "inspiration" - and it insists on being somewhere else.
I'd begin by recommending you to keep present the operative idea of "what you want". If you are working on a book, you WANT to keep writing that book, when nothing comes because your mind is somewhere else - like re-living a bad past experience - it can quickly devolve into a tug of war, of what YOU want to write Vs where your mind's focus wants or even needs to be.
What I find most helpful to get back into the writing mindset when I'm in a place where I can't manage to work on something I want, is to surrender control. Which in principle will be very frustrating, to begin with, after all, that manuscript won't finish itself or that post you need for work has a deadline.
The thing is, the more you fight it, that's what you do, fight. But if you allow yourself the freedom to try something different, you won't ever have the so-called "writer's block". You will always have something to write, even if is not what you intended initially. Take this blog post, for example, is something you wrote while not being able to write something else, and you think this is bad, but I'm telling you is not, is part of the process. Allow yourself to write completely unrelated stuff, maybe try some farfetched scenes you know won't end up in the story, do crazy things like writing a bit about what if one of your characters were in your favorite movie. If your mind keeps slipping into a traumatic event - like your mugging - turn it into a story, what if it happened to the protagonist of your story? what if your protagonist was the one that mugged you?
Before long you'll realize you can always, without exception, write; the trick is not fighting your brain for focus but lead it gently back to where you need it.
RE: Writer´s block - How do you deal with it?