I will sit down with a pack of cookies and eat the entire thing until it hurts and I cry, how can I stop doing this?

Get some help. Binge eating usually is done to quell an unwanted feeling, feeding an emotional hunger. It can be old memories or newer ones but mostly unconscious ones by then. It's a complex knot to untie. Counseling with someone who understands eating disorders is a good idea. What painful thing have you had to do so long that it hurt till you cried? Sit and think about that for a while.
Get some help. Help is available through overeaters anonymous, and/or counseling. A psychiatrist may prescribe medicine to treat underlying depression or anxiety, or to reduce the intensity of the impulse to binge.
Satisfaction. People may eat, drink, smoke, shop, gamble, do drugs, sleep around, in order to relieve anxiety and feel 'satisfied'. Exercise, art, writing, music are some productive ways to get the same 'feeling'.