In a properly working device, all current that goes out one power lead MUST go back through the other power lead. To get 120vac from a 240vac circuit, the return lead is the neutral...for 240vac, the return lead is the other 240vac lead (return is somewhat ambiguous, since power is actually flowing back and forth).
A GFCI circuit looks for the 'loss' of some of that return current (IOW, it somehow made it to ground instead of the current carrying conductor - the neutral or the other 240vac hot lead). That 'loss' of current could easily be going through you to ground. That imbalance means current is going somewhere it is not designed to go. Back at the main panel, ground and neutral are tied together, but depending on the length of the wires and the amount of current that they are carrying, at the other end, they may or may not have exactly the same potential (which is the reason why the code was changed to separate them). The ground is a safety return wire that should provide a path to trip the circuit breaker if there's a short and neutral is compromised in some way. If you're moving the device, it is my understanding that the circuit must be brought up to current codes, and that would mean running a new cable. The code does not allow you to use a ground from another cable to augment the ground at the newly installed device.
So, a GFCI does not require a ground attached at all to work...it is looking for there to be the same power in both power leads, and if it isn't, there's a problem and it trips, removing power to protect you.