InstallShield: cannot extract icon with index 0
Windows Installer Advertised Shortcuts require an icon resource. At build time, InstallShield will extract this resource and populate the Icon table. This error is saying that this wasn't possible.
The simplest solution is to add an icon resource to your project and rebuild the EXE:
- Right click your WPF project in Solution Explorer and select Properties in the menu;
- In the Properties page, select the Application tab (it should be already selected);
- Go to the Resources section and click on the (...) at the right of the Icon field;
- Select your desired .ico file and click Open.
Alternatively you can set the shortcut to not be Advertised and Windows will resolve a default icon for you when the start menu is displayed. You will lose some of the advertisement capabilities of MSI in doing this so I really suggest that you just provide it with an Icon.
I was getting this problem, I try a lot of solutions on the web, but the only way that works for me:
- Expand the setup project (Solution Explorer)
- Expand the menu "Configure the Target System"
- Double click on Shortcuts folder
- Here you will find 2 output you set up in the project wizard.
- Select one of them, and find the property Icon, click to (...) to browse the propertly icon.
- Do the same with the second one output built solution.
- Rebuild your project!
Regards,