As an anxiety sufferer you'll know that your mind is crowded with doubting thoughts. The "what ifs". I'm sure like many others, I wish there was a off switch. Instead, there isn't exactly an off switch, but training.
Getting rid of the doubting thoughts is, I think, the most difficult part of anxiety as it's what stops you from doing the things you want to. But, with time it is possible to train your thoughts. It is extremely hard and it is like a battle against an equal force.
Through CBT, for example, you can begin to tackle this. You may even get to a point where you can block off your thoughts; section them. You can do this through distractions and practice. Of course, the one thing that will eat the evil thoughts is doing the action that it doesn't want you do to. But, don't feel angry at yourself if you can't tackle it. That's understandable; it's better to start off small and things like CBT can help you to do this.
It all takes time, so don't expect something to happen overnight. But, the more you work at it, the easier it's going to become. Don't get me wrong, I still have doubting thoughts, especially with health anxiety, but they're no where near as strong as they used to be. It has taken me a long to time to get where I am, but it's possible to get there with the help of therapy, medication and so on. Stick with it!