cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
jedimaster_mark
Level 7

InstallScript event handler question

Okay, I have an inherited InstallScript project that I am working with. The project uses "program ... endprogram" (so, if you don't know what I'm talking about, chances are you can't help me). I know this is not ideal. I'd love to change it, but updating 4000+ lines of InstallScript by myself when I maintain a good two dozen or so other installers isn't exactly time practical.

Anyway, for years now it has come along fine. Recently, I've had to make some changes that require little applets we wrote internally to be run during install. Obviously, this initiates changes that the installation project isn't aware of. One of the changes also requires that I run an applet on uninstall to undo some things we're doing during install. So here's my issue. There's no "uninstall" routine now. As near as I can figure, "uninstalling" from Add/Remove Programs simply removes the files and registry entries that the install project put there; it's automatic, or so it seems. I see no place in the code that appears to be any form of intentional uninstall routine.

So I have nowhere to add a LaunchAppAndWait to kick off this app. Given the nature of the project, if I add an OnUninstall event handler, will it even execute? If not, is there some way that I can guarantee that this gets executed?

Thanks,
Mark
Labels (1)
0 Kudos
(3) Replies
esiemiat
Level 9

It is my understanding that install events do not get called when the InstallScript code uses program...endprogram.
0 Kudos
RobertDickau
Flexera Alumni

(As an aside, the "OnShowUI" help topic describes a simple way to convert from a program...endprogram procedural script to an event-driven script.)
0 Kudos
jedimaster_mark
Level 7

That would certainly be a good thing. I shall look into that. Thanks for the tip.
0 Kudos