Installation Error: "Program ended with an error exit code" (Windows)

Symptom

During the installation process on a Windows computer, you receive the following error message:

"Program ended with an error exit code"

Cause

This error is usually caused by antivirus programs or Microsoft OneDrive interfering with the installation process.

Solution

Please follow these steps:

1. Disable any antivirus program while running the installer.

2. Disable Microsoft OneDrive for the installation. This Microsoft support article explains how: Turn off, disable, or uninstall OneDrive

3. Make sure to run the installer as administrator:

  • Open the Start menu.
  • Select Settings > Control Panel (depending on your Windows version).
  • Open User Accounts.
  • Select the Users tab and make sure Administrator is displayed in the Group column.

4. If none of these steps are helpful, run the installer in Safe Mode, as explained in this article provided by Microsoft Support: Windows Startup Settings