I was looking into the uninstall functionality for app packages and noticed in the RN the following sentence:
"When you install an app with the AllowMultipleInstalledVersions option set to false, the uninstall script of that app (if present) will automatically be triggered. Also, the uninstall will be executed forcefully, meaning that the app will be removed even when the script fails."
We want to avoid that when a user installs a newer version on top, that data linked to the solution is removed. Is there a way to differentiate if the uninstall is called through an uninstall action or if the uninstall was called as part of installing another version?
Or should we (and how) set the 'AllowMultipleInstalledVersions' to true to avoid that data is being cleaned up during an upgrade to a newer version?
Hi Michiel
I know that it exists, but I don't know if it properly works. Regardless, the tooling to create dmapp packages don't have support for the uninstall script. What the documentation is referring to for uninstalling is the files/directory in 'C:\Skyline DataMiner\AppPackages\Installed'. This wouldn't uninstall the components of the app package. It would just remove the registration that the package was installed.
Thanks for your reply. Does this mean that packages should not implement the entry point as it doesn't work properly and raise an issue/feature task or that we shouldn't implement it at all as it was not designed to be used by packages?
[AutomationEntryPoint(AutomationEntryPointType.Types.UninstallApp)]
public void Uninstall(Engine engine, AppUninstallContext context)