Every writer has the occasional setback. I experienced one recently, and felt sorry for myself for a couple of days, but after the two days, I bucked up and got back on the horse.
The truth is, getting back on the horse is not the hard part.
The hard part is those couple of days of feeling bad. You have to face the problem, think about it, dwell on it, and look at it from each angle. That's the non-action part, where all you see is Obstacle. The action part, where you have the opportunity to do something about said Obstacle, is the easier of the two by far. Because now you are in motion, and moving toward a solution (or, paraphrasing Edison, not another failure but another way it won't work).
I have heard the phrase "Don't give up" so many times, it's probably engraved on my eardrums by now. But it's true. You can't publish if you don't write something. You can't get that dream job if you don't apply. You can't get through that door, but by gosh, you can try the window. And failing that, grab a reciprocating saw and cut yourself a hole through the wall, darn it.
Keep writing. Keep trying. Stay on that horse, and if you can't stay on it the first time, get back on!