This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Windows cannot find icon path on Win 2003 64bit
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
Jan 27, 2010
11:05 AM
Windows cannot find icon path on Win 2003 64bit
I have just starting testing my install on Windows Server 2003 64bit and have found a problem with the icon path of the shortcuts I am creating - everything works fine on 32bit.
The problem is that when I go into the properties of the shortcut and click Change Icon, a messagebox pops up saying 'Windows cannot find the file %ProgramFiles%\MyFolder\MyIcon.ico'. If I change the path to be %ProgramFiles(x86)%\MyFolder\MyIcon.ico then it works.
The problem is that when the shortcut is created, either Windows or Installshield is substituting the path to the icon incorrectly by using the 64bit Program Files path instead of the 32bit path.
I am using the AddFolderIcon function from InstallScript to create the icons and even if I hard code the path to use for the icon the substitution still takes place.
Is this a bug in InstallShield 2010 SP1?
Does anyone know a way around this?
Thanks.
The problem is that when I go into the properties of the shortcut and click Change Icon, a messagebox pops up saying 'Windows cannot find the file %ProgramFiles%\MyFolder\MyIcon.ico'. If I change the path to be %ProgramFiles(x86)%\MyFolder\MyIcon.ico then it works.
The problem is that when the shortcut is created, either Windows or Installshield is substituting the path to the icon incorrectly by using the 64bit Program Files path instead of the 32bit path.
I am using the AddFolderIcon function from InstallScript to create the icons and even if I hard code the path to use for the icon the substitution still takes place.
Is this a bug in InstallShield 2010 SP1?
Does anyone know a way around this?
Thanks.
(1) Reply
Jun 09, 2010
05:09 AM
Same issue on x64 editions of Vista and Windows 7 (and I guess on all x64 OS). For InstallScript installations the solutions is to add the following code before the call to the AddFolderIcon function.
if (SYSINFO.bIsWow64) then
StrReplace ( szIconPath, PROGRAMFILES, "%ProgramFiles(x86)%\\", 0 );
endif;
This is only valid for installing 32bit applications in the "Program Files (x86)" folder.
if (SYSINFO.bIsWow64) then
StrReplace ( szIconPath, PROGRAMFILES, "%ProgramFiles(x86)%\\", 0 );
endif;
This is only valid for installing 32bit applications in the "Program Files (x86)" folder.