Installing softwares in Program Files(x86) will not crash your system always,it is the default installation directory for all 32-bit Software,for 64-bit software the default directory is Program Files. Program Files or Program Files (x86)-Where to place downloaded program My computers are both running Win 7 64-bit. I am thoroughly confused when it comes to placing programs that I download into their proper folders: That is, program files (x86) vs program files.
Definition of: Program Files x86Starting with Windows Vista, the 64-bit versions of Windows have two Program Files folders. The regular Program Files folder holds 64-bit applications, while 'Program Files (x86)' is used for 32-bit applications. Installing a 32-bit application in a PC with a 64-bit Windows automatically gets directed to Program Files (x86). See Program Files and x86.
THIS DEFINITION IS FOR PERSONAL USE ONLY.
All other reproduction requires permission.
The Computer Language Co Inc.
All rights reserved.
We strongly encourage you to read our updated PRIVACY POLICY and COOKIE POLICY.
×My boss needs an installer to setup software onto one of our client's machines. He wants the software to be installed specifically into 'C:Program FilesHisApplicationName', not 'C:Program Files (x86)HisApplicationName'. I know the correct answer would be to rewrite the software to accomodate any directory the user chooses to install to, but unfortunately, this is very old sofware & needs to be installed tomorrow, so we just want to force the installer to point to the client's 'Program Files' directory.
My problem though, is when I hardcode the filepath into the installer's 'DefaultLocation' property, the installer still tries to point to the Program Files (x86) directory instead.
Is there any way to force the windows setup/installer package to point to Program Files & not 'Program Files (x86)'?
Thanks.
goalie35goalie351 Answer
What you are asking to do simply isn't possible with Windows Installer with the exception of one unsupported subversive hack.
Set the INSTALLDIR
to C:Progra~1.....
See, MSI has functionality for backwards compatibility that automatically 'fixes' any hard coded references of C:Program Files
to C:Program Files (X86)
when the MSI is marked as 32 bit. It fails to calculate the shortname version and redirect it so my hack works. Assuming they haven't disabled short filename system.
The only proper way to install to C:Program Files
is to mark the MSI as 64-bit and use the ProgramFiles64Folder
property instead of the ProgramFilesFolder
property.
BTW, if your boss won't believe you, then I suggest finding a new boss. I've been writing installers for 16 years and I never let some PHB make decisions like this. I'm the Windows Installer expert, not him.
Peter Mortensen