Is it too late?

So we had some feeding troubles after we brought our son home from the hospital. He had a great latch in the hospital but then stopped latching shortly after we came home. He lost a good bit of weight so per the pediatrician we had to supplement with formula. I’ve been pumping continuously this whole time and he has been receiving 50% breast milk and 50% formula bottles. He will be 4 weeks tomorrow. Is it too late for him to get a good latch now? I’m really wanting to breastfeed