ProgramData not clearing on uninstall.

Got a problem you cannot solve? Try here.
FridgeWheeL
Posts: 7
Joined: Tue Sep 17, 2013 11:47 pm

ProgramData not clearing on uninstall.

Postby FridgeWheeL » Thu Sep 19, 2013 1:17 am

Good Day

I am currently busy rewriting our MSI based installer and I am using the IA Native Engine with the Studio version of IA NX.
The problem I have is as follow:
I run the setup to install our product which has multiple services. The installer extracts the setup to the C:\ProgramData\{productkey}
In C:\ProgramData\{productkey1234…} there is a file {productkey1234…}.native.data file which I can see is log of the installation. As a simple example (to explain my problem) this file will have entries as follow:

Line 1:Step A
Line 2:Step B
Line 3:Step C

Once my installation is complete I run the setup again to uninstall the product.
At this stage the product has been removed but the C:\ProgramData\{productkey} directory still remains.
I then run the very same version of the installer again and the product installs perfectly fine, but the {productkey1234…}.native.data file inside C:\ProgramData\{productkey1234…} gets modified as follow then:

Line 1:Step A
Line 2:Step B
Line 3:Step C
Line 4:Step A
Line 5:Step B
Line 6:Step C

Now when I try to uninstall our product again, on the Apply Uninstall line I get 1 error (the specified service does not exist as an installed service) for each service our product installed. I gathered that it uses the {productkey1234…}.native.data file to undo the installation and with this file now having double install entries it tries to uninstall our services twice.

Although I get these errors, the product uninstalls fine. If I run the setup again and the uninstall again, I get 2 errors for each service since the {productkey1234…}.native.data file now contains triple entries.

When I look at the predefined variables ENGINECACHE: it states as follow: This folder is always removed after uninstallation, although a reboot may be necessary for the removal to finalize.
I tried rebooting after the 1st install & uninstall but the C:\ProgramData\{productkey1234…} directory does not clear after the reboot.

I also went and started a new native template project which installs one of our services and then uninstalls it, with this the ProgramData directory gets removed and cleared perfectly.
As soon as I copy all of my installer code over to the new project, I sit with the same problem again.

Is there anything else I can check to figure out why an uninstall of our product does not remove the C:\ProgramData\{productkey1234…} directory?

Regards

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: ProgramData not clearing on uninstall.

Postby FrancescoT » Fri Sep 20, 2013 10:04 am

Dear User,

It is not easy to share with you a possible suggestion without having your project files.

I have just tried as you to replicate the same with a test project, but the "programdata" folder is removed correctly at un-install.

For sure, in your case this happens because the folder is not empty when the IA engine tries to delete it.
Very probably this has a relation with the un-install service process that seems to not complete correctly with your package.

I may suggest you to verify if those services are effectively installed (just before your run the un-install) and if they are, to try to un-register them manually from command line (to see if you receive any other info about a possible error).

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

FridgeWheeL
Posts: 7
Joined: Tue Sep 17, 2013 11:47 pm

Re: ProgramData not clearing on uninstall.

Postby FridgeWheeL » Mon Sep 23, 2013 2:27 am

Good Day FrancescoT

First of all I would like to say thank you for taking the time to try and re-create my problem.

I am completely new to InstallAware or any installers for that matter and I am used to manual intervention on pretty much anything.
I used complete customized Dialogs as well as a custom variables for indicating an uninstallation of the product.

With this said it came down to this:

When running the same installer after an initial installation, the MODIFY pre-defined variable is set to TRUE and the REMOVE pre-defined variable to FALSE.

I used my custom variables to navigate though the correct Dialogs to interview the user on what he wants to do and populated once again custom variables all the way though the code up until the Apply Uninstall command and never defined the MODIFY or REMOVE pre-defined variables.

With these defaults i guess the Apply Uninstall could never completely do everything it is supposed to do thus resulting in engine cache never being cleared correctly.
As soon as I applied the correct values (MODIFY = FALSE & REMOVE = TRUE) to these two variables the Apply Uninstall cleared my Program Data as expected.

I do have one more question though and that is a more thorough explanation on the PERSONALIZED pre-defined variable.

Once again thank you for your time.

Regards

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: ProgramData not clearing on uninstall.

Postby FrancescoT » Tue Sep 24, 2013 3:42 pm

... I'm glad you solved!

The PERSONALIZED pre-defined variable holds the selection state of the "Some features" radio button, that is available by default within the "SetupType" dialog.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

FridgeWheeL
Posts: 7
Joined: Tue Sep 17, 2013 11:47 pm

Re: ProgramData not clearing on uninstall.

Postby FridgeWheeL » Tue Sep 24, 2013 11:34 pm

Thank you FrancescoT

I appreciate all your help :)

Regards

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: ProgramData not clearing on uninstall.

Postby FrancescoT » Thu Sep 26, 2013 3:41 pm

:D :D :D
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE


Return to “Technical Support”

Who is online

Users browsing this forum: No registered users and 116 guests