Jennifer Lopez confesses that it was hard for her to function following her split from husband Marc Anthony.
The pair called it quits in July 2011.
Jennifer found it particularly difficult to face the end of her relationship with Marc because of the two children they share together, four-year-old twins Max and Emme.
"I was going through a divorce and the breakup of a family, which was devastating to me because family means everything to me," Jennifer told Hollywood Life.
"I didn't want to be the woman who stayed in bed for months. I did do that a little, but I knew I had to get through it."
Jennifer was committed to transforming the negative event into something positive for her life.
The star immersed herself in her work to ameliorate her pain and created her hit single Dance Again.
"I had to figure out what I did wrong that I was in a relationship where I was accepting situations that weren't good for me. If you're allowing yourself to be in a bad relationship, you need to understand why,” she explained.
"I had to turn [the breakup] into something better. I thought, 'I don't want to just survive it, I want to come out better.’
"I had to beg and beg Enrique to give it [that song to] me. I told him, 'That's my song.' And finally, he gave in. Dance Again became my anthem... an expression of what I needed to do at that time in my life and for what I was taking on with [my career]. It was a beautiful metaphor that became my reality."