Check if a product already is installed

 
We have added a new condition that can be used to check whether or not a product is already installed in the system. This condition is very useful if it is combined with for example the MSIEXEC command that is used to run MSI installations. By combining the MSIEXEC command with this new condition you can make sure that the installation is only run if the product is not installed. This will speed up the installation process in many computers.
 
The syntax of the new condition is:
 
IF INSTALLED("Product name")
 
  Do some stuff

END IF
 
And if you need to check whether or not a product is not installed in the system, you can use the following syntax:
 
IF NOT INSTALLED("Product name")
 
  Do some stuff

END IF
 
Instead of a product name you can also test against a product id (for example: "{4815BD99-96A4-49FE-A885-DCF06E9E4E78}"). The example below shows how to combine the IF NOT INSTALLED condition with the MSIEXEC command:
  


The MySetup.msi installation package will only be run if the application (with the name "My Application") has not been installed since before. If the application already is installed the MSIEXEC command is ignored.
   
< Go back
     

 

SamLogic