the product code now a days for laptops are embedded in the bios, so if you've reformatted, you need to use the recovery partition to re-install windows, or get your're manufacturer specific copy of windows, you cant just download any old version and install it, my laptop, (Packard bell) I can download my version of windows 7 from their website.
I know this is for Windows 8, but you can try this: https://itsolutionsblog.net/3-ways-to-extract-the-windows-8-product-key/