I have a pair of custom actions one that moves some deprecated files to a temp directory and another one that runs if the installer rolls back to put them back. I have to use a custom action because the previous installer was installshield.
Below are my custom actions:
<CustomAction Id="DeleteUserAdminDeprecatedFiles" BinaryKey="FileSearchCA" DllEntry="DeleteUserAdminDeprecatedFiles" Execute="immediate" Return="check" />
<CustomAction Id="RestoreDeprecatedFiles"
BinaryKey="FileSearchCA"
DllEntry="RestoreDeprecatedFiles"
Execute="rollback"
Return="ignore"
/>
<CustomAction Id="SetRollbackData" Property="RestoreDeprecatedFiles" Value="RootDir=[DEPRECATEDFILESROOTDIR];TempDir=[DEPRECATEDTEMPORARYDIR]" Execute="immediate" Return="ignore"/>
Below is the scheduling of these actions:
<Custom Action="SetRollbackData" After="DeleteUserAdminDeprecatedFiles">
OLD_VERSION_FOUND OR <!--Run if we are doing a major upgrade (msi -> msi).-->
REMOVEINSTALLSHIELD
</Custom>
<Custom Action="DeleteUserAdminDeprecatedFiles" Before="InstallFinalize">
OLD_VERSION_FOUND OR <!--Run if we are doing a major upgrade (msi -> msi).-->
REMOVEINSTALLSHIELD <!--Run if we are upgrading installshield instance.-->
</Custom>
<Custom Action="RestoreDeprecatedFiles" After="InstallInitialize"/>
Then in the log I get:
MSI (s) (04:74) [11:31:22:162]: Doing action: DeleteUserAdminDeprecatedFiles
Action 11:31:22: DeleteUserAdminDeprecatedFiles.
Action start 11:31:22: DeleteUserAdminDeprecatedFiles.
MSI (s) (04:3C) [11:31:22:171]: Invoking remote custom action. DLL: C:\Windows\Installer\MSI8804.tmp, Entrypoint: DeleteUserAdminDeprecatedFiles
SFXCA: Extracting custom action to temporary directory: C:\Windows\Installer\MSI8804.tmp-\
SFXCA: Binding to CLR version v4.0.30319
Calling custom action FileSearchCA!FileSearchCA.FileSearchCA.DeleteUserAdminDeprecatedFiles
Starting UserAdmin delete deprecated files Custom Action.
MSI (s) (04!50) [11:31:22:376]: PROPERTY CHANGE: Adding DEPRECATEDFILESROOTDIR property. Its value is 'C:\Program Files\Duck Creek Technologies\ExampleUserAdmin\bin'.
MSI (s) (04!50) [11:31:22:380]: PROPERTY CHANGE: Adding DEPRECATEDTEMPORARYDIR property. Its value is 'C:\Users\LMUser\AppData\Local\Temp\t3n1evfp.dwa'.
Action ended 11:31:22: DeleteUserAdminDeprecatedFiles. Return value 1.
MSI (s) (04:74) [11:31:22:429]: Doing action: SetRollbackData
Action 11:31:22: SetRollbackData.
Action start 11:31:22: SetRollbackData.
MSI (s) (04:74) [11:31:22:437]: Note: 1: 2723 2: SetRollbackData
DEBUG: Error 2723: Custom action SetRollbackData specifies unsupported type
Any help resolving this would be much appreciated.
I'm an idiot I got it fixed.
I had to change:
To: