Drink in moderation or abstain and you'll never have them, you created it by drinking to much, but to be fair when I used to get them I'd have pink lemonade and a big bowl of Menudo with fresh corn tortillas...)
Drink pickle juice. I know it sounds nasty but it has all kinds of electrolytes that will replace the ones you lost. In the future, if you have a glass of water between each drink you won't have a hangie!!