I am using this code in my custom UninstallProgressForm
(Custom Uninstall page (not MsgBox)) to define a message after the uninstall (that does not have the original uninstaller messages):
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
begin
case CurUninstallStep of
usPostUninstall:
if not WizardVerySilent and UninstallSilent then begin
MsgBox(CustomMessage('UninstallComplete'), mbInformation, MB_OK);
end;
end;
end;
I want to hide this message at determinate moment, at uninstall my previous version (if is present). For uninstall my previous version i am using this code: How to detect old installation and offer removal?. I have modified the code of the previous link with this code to run the uninstaller if there is a previous version: Executing UninstallString in Inno Setup