Posts

Showing posts from August, 2008

Easy way of Copying Condition in Custom Action

Image
I have learnt an easy way of copying condition directly in one Custom Action from other. This is totally on my experience, and I have not found any material for it on net too. So here it goes... Suppose you are making a CustomAction2 and have added it in the sequence as shown : And now you have to mention the condition same as that of CustomAction1, which in this case is "NOT Installed AND NOT PATCH", you have to click on CustomAction1 in the sequence and it will be like this: You can see the Condition in the greyed area. You cannot copy it directly, but what you have to do is: go to any of the other tab from this situation, be it Properties or Details tab. All you have to do next is to come back to your Location tab. And here you see the result.The Condition is automatically copied to the CustomAction2. Go ahead and try this out. It is really fun and easy. It will save you some time too.

Exclusion List

Exclusion List • Manual Checks: Exclude (delete) any unwanted files and folders. Some common file extensions that should usually be excluded are listed below. If the resource you are deleting is a keypath (indicated by the key symbol) you must ensure the related component has been assigned a new keypath. If the component is now empty it can be deleted. Common Items: HKEY_USER_SELECTABLE\Software\Shortcuts Event log registries. All VCache Entries Shutdown Entries Uninstall Entries Your Username if Captured *.log-app specific services / hosts – These must be handled appropriately Folders/ Files referring to Wise Folders/ Files referring to InstallShield Any cookies Any file from the dependency applications that has got captured must be excluded. Cache Temp Tmp Bag Log – Examine in notepad to see if they are relevant or not. • Files *.REG files _isreg32.dll setup.exe install.log install.exe install.ini unwise.exe Uninstall.xml Upgrade.exe Update.exe uninstall.cif uninstall.cfg / uninstall...

Troubleshooting Unnecessary Repairs

Sometimes you may encounter the problem of unnecessary repairs of MSI while launching the shortcut in the same logged in user. Here is the way to troubleshoot this problem. You can go to eventviewr (by typing eventvwr in Run command) then to applications and check the latest error message after repair. It will tell you which component is missing and because of which MSI went for self heal. You can now check out this component in your package and see what the problem is. Maybe your keypath is a moving target for that component. There are other methods too which can be used in case the above does not work. These are Logs/Gap capture. More on this later.

Why Custom Action Type 51 is Required

If you have always wondered why we need to anSet Property Custom action when there is already a Property table to handle it, then this is for you. Suppose we have to create a property based on the value of another property - in that case we cannot use the Property table to handle this. There will be a circular reference in which one property would be based on the other. In this scenario we use Set Property Custom Action. To affect a property used in a condition on a component or feature, the custom action must come before the CostFinalize action in the action sequence.

Order of Precedence for Properties

The installer sets properties using the following order of precedence. A property value in this list can override a value that comes after it and be overridden by a value coming before it in the list. 1) Properties specified by the operating environment. 2)Public properties set on the command line. 3)Public properties listed by the AdminProperties property set during an administrative installation. 4)Public or private properties set during the application of a transform. 5)Public or private property that set by authoring the Property table of the .MSI file.