Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Installer is writing files to "C:\Program Files (x86)" instead of "C:\Program Files"

I’m converting an existing Inno script to install a 64-bit Windows application. I’ve set the x64 Inno properties in my script, but the installer is still copying files to the x86 folder when I run it.

[Setup]
PrivilegesRequired=admin
ArchitecturesInstallIn64BitMode=x64
ArchitecturesAllowed=x64

Here’s a snippet of my installer’s log file:

Setup version: Inno Setup version 5.6.1 (u)
Windows version: 10.0.22621  (NT platform: Yes)
64-bit Windows: Yes
Processor architecture: x64
User privileges: Administrative
64-bit install mode: Yes
  ...
Non-default bitness: 32-bit

This is how I specify a file to be copied:

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Source: "bin\{#TesterWpfExe}"; DestDir: "{app}"; Flags: ignoreversion

What’s odd is that I’ve converted another Inno script to 64-bit and it is working just fine. It seems there must be something different about this problematic script, but I have not figured out what the problem could be.

Are there other factors that could be causing the installer to revert to 32-bit mode?

Any suggestions for troubleshooting this?

>Solution :

You probably have the application (same AppId) already installed on the machine.

Reinstalling it will (by default – UsePreviousAppDir) use the previous installation folder, no matter that you have possibly changed the DefaultDirName (from {pf} to {autopf}?).

Uninstall the application and try a fresh installation.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading