make a virtue (out) of something idiom
将(尤指坏事)变好事;对…因势利导
to use something, especially a bad situation, to your advantage
I had a couple of months to spare between jobs so I thought I'd make a virtue of necessity by acquiring a few new skills. 我换工作期间有几个月空闲时间,因此不如趁此机会学一些新技能。