Archive: silent - callback function that validates a custom page


silent - callback function that validates a custom page
Hi all,

When uninstalling first thing the uninstaller does is to show a custom page that asks:
a) uninstall the product from the machine
b) disable for current user

Then in the "Function un.ValidateSelection" (where: UninstPage custom un.UninstallModePage un.ValidateSelection) I do:
if users choses a, the uninstaller goes normally further. If the user choses b, the uninstaller runs an exe from my application and then quits, as the product shouldn't be uninstalled, and my exe will take care of just disabling for current user.

This works ok in a non-silent uninstall, but in a silent uninstall, the function un.ValidateSelection is not called. Where and how should I write the neccesary code? meaning the code that checks if a) or b) should be done (in a silent uninstall can be part of the cmd line param) and in case it's a) to run an exe and to quit the uninstaller?

Thx,
Viv


haven't I been clear with my question, or there is no "right" answer for it?

Thx,
Viv


You should implement the working code in the sections and only have the custom page set a variable that tells the code what to do. That same variable can also be set in un.onInit according to the command line.


Yes, that's indeed better :)

Thx,
Viv