The SATA controller’s mode of operation cannot be changed to AHCI after Windows 7 is installed, because the AHCI driver will be missing and the system cannot boot. Here is how to address this without repairing or re-installing Windows.
With the SATA controller still running in IDE mode, start the registry editor as administrator. To do that, type regedit in the Start menu’s search box (without hitting Enter), then right-click on the single search result in the Programs category, and select Run as administrator. Then navigate to the key HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\msahci. Edit the value for Start and set it to 0:
Then shut down normally and enter the Bios setup while rebooting (by pressing F2, Del, or whatever applies to your hardware). Now you can change the IDE mode to AHCI and Windows will load the AHCI driver the next time it starts up.