Not Ovulating??

So I went to the OB and she did test and seen that I'm not ovulating and I have pcos and thyroid problems. She mentioned putting me on metformin next week when I go in. Has anyone gotten pregnant from it and how long did it take?