Viagra- the little blue pill- not only helps men with erectile dysfunction, but could also help women cope with menstrual cramps, according to a new study.

Primary dysmenorrhea, also called PD, is the medical term for painful cramps during period. Previous research has shown that taking Sildenafil citrate (brand name Viagra) orally could reduce menstrual cramps. However, side-effects of using this drug orally such as headache prevented the drug from becoming a standard treatment for cramps.

Penn State College of Medicines researchers who conducted the current study wanted to see whether administering Viagra via the vagina helped alleviate menstrual pain.

Their study included a small sample of 25 women between ages 18 and 35 years. Participants were either given sildenafil or a placebo drug.

Women who got Viagra reported less pain than the control group. According to researchers, the drug might work by dilating the blood vessels and increasing the blood flow.

"If future studies confirm these findings, sildenafil may become a treatment option for patients with PD," said Richard Legro, professor of obstetrics and gynecology and public health sciences. "Since PD is a condition that most women suffer from and seek treatment for at some points in their lives, the quest for new medication is justified."

Researchers add that only future studies will show if the treatment will work in women. Currently, women use painkillers like ibuprofen to cope with pain. However, not all women can tolerate ibuprofen plus long-term side-effects of using the drug are quite serious, including ulcers and kidney damage, according to a news release.

The study was published in the journal Human Reproduction.

Viagra, Pfizer's mega-successful drug currently makes $2 billion (2012) in just prescription sales. However, it wasn't originally designed to help middle-aged men get an erection. Peter Dunn and Albert Wood, both British Pfizer scientists, created sildenafil citrate in 1989. The idea then was to use the drug as treatment for high blood pressure. But, the drug failed to clear clinical tests.

However, during the trials, participants reported an increase in erections. The effect of the drug on volunteers' sex lives was so great that they wanted to continue using Sildenafil citrate even after the tests for blood pressure and angina were over.

The company then conducted studies to check if the drug could be used as a treatment for erectile dysfunction.

Currently, Viagra accounts for 49 percent of the market for sexual dysfunction treatments, The New York Times reported.