Windows Installer InstallAware for Windows Installer Header Image Windows Installer without Rocket Science

  Learn More

   

MSI Custom Action Comparison

  Download Now      Buy Now

 

One simple measure of how much easier it is to perform common installation tasks with InstallAware, is to look at the steps required to read from a text file on a user's machine. InstallShield requires that you write a custom VBScript or DLL, which then must be integrated with the setup as an MSI custom action.

 

InstallAware's built in setup commands let you perform the task in five steps (which do not require programming skills) while completely avoiding the pitfalls of programming Windows Installer to perform a custom action.

 

 

InstallShield vs. InstallAware

InstallShield MSI Project

 

InstallAware MSI Project

 

  1. Write a custom VBScript that reads from the desired text file. Include a function that lets you know whether or not the script has been executed by the Windows Installer engine.
  1. Select the MSIcode view.
  1. In an InstallShield Basic MSI project, right-click on the Custom Actions root node and choose Custom Action Wizard. The Custom Action Wizard is displayed.
  1. Select a line in your project code.


  1. Click Next. The Basic Information Panel is displayed.
  1. Enter R in the line of code. The Read from Text File command is displayed. Click Enter.
  1. Enter the name of your custom action in the Name field. Click Next.
  1. In the Read from Text File window, enter the name of the file you want InstallAware to read from in the Read from File field.
  1. The Action Type panel is displayed.
    Select Run VBScript code from the Type list.
  1. Enter a variable name to hold the read text. Click OK.
    The code needed to read from a file on the target system is created and added to your project.
  1. Select Stored directly in the custom action from the Location list. Click Next. The In-Sequence Scripts panel is displayed.
 
  1. Copy and paste your VBScript into the field provided.
    Click Next. The Additional Options panel is displayed.
 
  1. Select the Deferred execution in System context option from the In-Script Execution list. Click Next.
    The Insert into Sequence panel is displayed.
 
  1. Select After ResolveSource from the Install UI Sequence list. Click Next. The Summary panel is displayed. Click Finish.
 
  1. Build and test the setup, including running it in silent mode.
    The custom action fails to execute. Maybe you used the wrong Windows Installer sequence.
 
  1. Repeat steps 2 through 8.
 
  1. On the Insert into Sequence panel, select After RegisterComPlus from the Install Execute sequence list. Click Next. The Summary panel is displayed. Click Finish.