Since InstallShield generated "setup.exe", there is an easy way to do silent installation. But I found the available solutions to silent uninstall is not working well for our product. Anyways I will give my findings.
Silent Installation
- First create a InstallShield silent response file(setup.iss). This file will record the actions which we do while installing
setup.exe -r
It will create setup.iss file in Windows folder. i.e C:\WINNT in my case.
Also you can use "-f1" option to create .iss file of your choice.
For Ex: setup.exe -r -f1"C:\win32vc8\setup_inst.iss"
- Now Install with silent option (-s or /s)
setup.exe -s
or
setup.exe -s -f1"C:\win32vc8\setup_inst.iss"
If everything go well, then application will be installed and can be accessed from Program files.
- Trouble shooting errors
Look setup.log file and make sure "ResultCode=0". By default setup.log file will be created at location where setup.exe is located. We can change this default location be providing alternative path with -f2 option.
What various non-zero ResultCode value means?
0 Success
-1 General error
-2 Invalid mode
-3 Required data not found in the Setup.iss file
-4 Not enough memory available
-5 File does not exist
-6 Cannot write to the response file
-7 Unable to write to the log file
-8 Invalid path to the InstallShield Silent response file
-9 Not a valid list type (string or number)
-10 Data type is invalid
-11 Unknown error during setup
-12 Dialogs are out of order
-51 Cannot create the specified folder
-52 Cannot access the specified file or folder
-53 Invalid option selected
Interactive Uninstall from command line.
setup.exe /uninst
Silent Uninstall. This is what worked for me.
Two ways
1) Using a Response File
To run an uninstallation using a response file:
- Prepare a response file for the uninstallation (.iss) by running Setup.exe with the /r argument:
Setup.exe /r
- Locate the Setup.iss file generated in the Windows folder and copy it to the desired location.
- Type the following at the command line (items in Italics represent data that is specific to your product's uninstallation):
IDriver.exe /M{Your Product GUID} /s /f1"<FULLY qualified path>\YourResponseFile.iss"
2) Simple Uninstallation
If you do not want to follow the script logic and want to uninstall the product, you can use the following command line:
IDriver.exe /M{Your Product GUID} /uninst
The /uninst parameter causes a forced uninstallation without opening the script. It rolls back the system changes made during the installation, including those from the MSI package and any InstallShield scripting.Note: For both of these uninstallation options, the /M argument is case sensitive.
Note: By default, the file "IDriver.exe" is located in the following path: C:\Program Files
This approach silently removed the application entry from Windows registry ( regedit). But it didn't remove the installed files.
If you wish to create Response file manually, here is the link for instructions http://kb.flexerasoftware.com/doc/Helpnet/installshield12helplib/CreatetheResponseFile.htm