There are two main ways to get zapped. In your case, assuming you're working at a bench or desk, neither is likely to be affected by your choice of footware.
The first, and most obvious, way to get a tingle is to grab one line with one hand and the other line with the other. There is no obvious way to rule this out - presumably you thought you needed to put your hands where you did. The standard way to minimize risk is the Pocket Rule: Keep one hand in your pocket when poking around in live equipment. Even this is not foolproof - if you're bellying up to a chassis and making contact with your chest, well, that's just as good as using your other hand.
The other way to do damage is through ground. Line voltages are capable of taking an alternate path through ground (as opposed to hot and neutral). This is the sort of path that standing in water can produce. There are two obvious safeguards, and the previous answers have dealt with them. A safety (or isolation) transformer will prevent ground paths from occurring, and a residual current breaker (known in the US as a GFI - Ground Fault Interrupter) will stop any unexpected flow before it has time to do damage.