I heard after filing for I140, I would not be able to extend the 17 months STEM OPT. Is that real?
If you try to extend your OPT after having filed the I-140, you may have problems with getting your OPT extension approved for the reason that the F visa does not allow immigrant intent and by filing the I-140, you will be showing your intent to immigrate, to some extent.
The immigration officer will review the surrounding factors to determine if you have shown immigration intent when reviewing your OPT extension request, such as keeping a foreign residence, etc. If they determine you have shown immigration intent, your OPT extension request might be denied.
The H visa does allow immigrant intent. So, you should not have any problems with getting an H-1B visa related to having filed an I-140.
You may also wish to file the I-140 and I-485 concurrently. By filing an I-485 you will have a valid visa status based on your pending I-485 known as AOS (adjustment of status). This AOS visa status allows you to stay in the US while your I-485 is pending. With the I-485 you can file an I-765 to apply for an Employment Authorization Document (EAD) (no additional filing fee). You can use the EAD to work in the US while your I-485 is pending. Once USCIS receives your I-765 it takes 1-3 months to get the EAD.
Please note that there is a risk with filing your I-485 before your I-140 is approved - if your I-140 is ultimately denied, your I-485 and any dependent I-485s will be automatically denied and you will lose the I-485 filing fees ($1,070 per person, $985 for children under 14). You will also lose your AOS status and EAD.