I'm having an issue upgrading an installation on Windows Terminal Server when installing as an administrator for all users.
The initial installation is run manually from the executable. The upgrade is initiated by the installed application, but with the flags /qn+ (no UI until completion). The installer UI has two options based on a checkbox (setting the property ALLUSERS): install for the current user or install for all users. When "install for all users" is unchecked, the install path is "C:\Users\%user%\AppData\Roaming". When it is checked, the install path is "C:\Program Files (x86)". The installer script uses three custom actions to attempt to accomplish this, all run after the Installation Execution Stage "Searches":
1. Set APPDIR to [APPDIR] for "Install, First time install" or "Uninstall, Regular uninstall" if ALLUSERS = "".
2. Set APPDIR to [ProgramFilesFolder]\[Manufacturer]\[ProductName] for "Install, First time install" or "Uninstall, Regular uninstall" if ALLUSERS = 1.
3. Set APPDIR to [ProgramFilesFolder]\[Manufacturer]\[ProductName] for "Install, Upgrade" or "Uninstall, Replaced by a new version" if TerminalServer = 1.
1 and 2 are intended for the manual, UI install. 3 is intended for the upgrade.
The regular install/upgrade works, but the all users upgrade ends up creating a new installation in the default APPDIR ("C:\Users\%user%\AppData\Roaming"). How can I get the silent upgrade to work for all users?
Thanks,
Scott