Thursday, September 17, 2009

Custom Actions and properties like TARGETDIR

If you want to pass an MSI property to your custom action exe, this is how you do it:

CustomAction -> Arguments: "[TARGETDIR]\".

Don't forget the trailing \
For Windows Installer properties such as [TARGETDIR] that return a directory, in addition to the brackets you must include quotation marks and a trailing backslash
If you forget, you'll spend 2 hours debugging an almost un-debuggable problem.

No comments:

Post a Comment