On Windows 7 and above, to reattach a Windows VHD (Virtual Hard Disk) file, do the following:
1. Open Command Prompt with elevated Administrator privileges
2. In the Command Prompt, copy the VHD file to your local hard drive by doing the following:
md C:\VHD copy X:\windows10.vhd C:\VHD (Replace X:\windows10.vhd with your VHD source file.)
3. Use diskpart utility to attach your VHD:
diskpart select vdisk file=c:\VHD\windows10.vhd attach vdisk
4. Look at which volume the VHD is attached to by doing the following:
list volume
5. Then, select this volume as follows:
select volume <the listed volume number> assign letter=z exit
6. Add this VHD to the Boot Menu by typing the following in the Command Prompt:
bcdboot z:\windows
7. Optionally, you can modify the description of the Boot Menu item that you’ve just added:
bcdedit /set {default} Description "Windows 10"
8. Reboot and enjoy!
