Without some details as to the errors and such I can give a good guess as to what is going on. The HDD contains info. created by Windows as to the hardware configuration of the system. With your first move of the HDD the system tried to open and boot from the miss-matched HDD and in doing so altered it's original information (master boot record, hardware .inf's, etc.). This caused the data loss and left the drive in an altered state. The second move back did about the same thing. The system tried to use a boot drive that had been altered in the other system and corrupted from it's point of view. So now it is also my guess that you have a few options. One is to buy a new drive and do a clean-fresh install of the entire system. You may then be able to buy an external mount to plug the original drive into and then may be able to open it to retrieve files that you need (not software or programs but pics., music, documents, etc.). Another option is to format the original drive and do a clean install though this is saying goodby to everything that may be recoverable on the HDD. Before you go the reinstall paths you can try (https://www.piriform.com/recuva) or similar software to try to recover the data on the drive. Lastly you may be able to repair the drive with software but more specific info. as to what errors are occuring is needed.