The pill

Hi, just a quick question. For my past two periods I have had really bad cramps. From the start till the end, and in between the two. The cramps when i’m not on my period are far better than when I am, but they are still painful and clearly there.

If I started taking the pill would this help me out with this at all? And if so, which would I need to take?

Thank you:)