cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
scotty22
Level 2

Weird Uninstall Behavior

Hello, community 🙂
I'm having a problem with my pure InstallScript project. When I install it and then uninstall it, it's okay. However, if I add OnMaintUIBefore and OnMaintUIAfter functions to it, when I try to uninstall from Add/Remove Programs, the computer says it's configuring the new software installation and never removes the program. The OnMaintUIBefore and OnMaintUIAfter have nothing in them except for MessageBox calls. This seems really strange to me that it won't let me uninstall at all. :confused:

Can anyone please help? I couldn't figure out why it's doing this despite looking at the docs. I need the Maint functions to do some cleanup and setup when the maintenance actually is supposed to be taking place.

Thank you in advance 🙂
Labels (1)
0 Kudos
(3) Replies
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

The default OnMaintUIBefore event contains code to display the maintenance type dialog and to kick off the maintenance operation selected by calling one of the Feature functions (FeatureRemoveAllInMediaAndLog, FeatureReinstall, etc.). Does your OnMaintUIBefore event still contain this code?
0 Kudos
scotty22
Level 2

joshstechnij wrote:
Does your OnMaintUIBefore event still contain this code?

Hmm, it doesn't. I've had this project passed off on to me from someone else, so I don't know what was there before.

If I create a new install script project should that give me the code I need?
0 Kudos
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

Yes, you can get the default OnMaintUIBefore code (or any other event) by creating a new InstallScript project and adding the event through the InstallScript view. You can copy/paste this code into your project's script and then modify it as needed.
0 Kudos