My weight

Nessa
So my husband and I had a small spat last night and it's hurt me to say the least. The whole topic revolved around a video about a man who loved his girlfriend even after she gained 100lbs. And I asked him would he love me, my husband answered yes but he said that he wouldn't be attracted to me after that... 
What he doesn't realize is that in the four years being with him, I've gained 40lbs. And to hear him say that, after which I realized we haven't had sex in months, it just kinda crushed me. I just wanted someone to hear me and understand why it hurt. I've tried to lose weight and it keeps coming back. Using know what to do, I'm want to lose weight but not if he will ONLY like me body that way. I don't know. I'm confused.