RegKeys Not Deleted On Uninstall?

Got a problem you cannot solve? Try here.
Post Reply
H4nd0
Posts: 92
Joined: Thu Nov 09, 2006 8:16 am
Location: Sydney, AU
Contact:

RegKeys Not Deleted On Uninstall?

Post by H4nd0 »

Hi Michael,

Write Registry Key HKLM\\Software\\Company\\Version\\Product, Something

creates the correct reg key + value. However, when I uninstall the key + value is removed (ie. Product) but the super-keys remain (ie. HKLM\\Company\\Version).

I thought IA takes care of this and removes all keys for me?

If not ... how do I force IA to purge the registry of all keys and values it wrote?

TIA,

James
MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Post by MichaelNesmith »

It will remove the parent keys if no further keys remain and if you originally created the parent. Otherwise, you can use Delete Registry.
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
H4nd0
Posts: 92
Joined: Thu Nov 09, 2006 8:16 am
Location: Sydney, AU
Contact:

Post by H4nd0 »

Hi Michael,

The installer did create all the keys/values.

The uninstaller _didn't_ remove the top level keys (but did remove all the sub values).

Is this normal behaviour or a bug?

Cheers,

James
MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Post by MichaelNesmith »

Hi James,

It certainly seems abnormal to me - but Windows Installer takes care of all that internally, so it might be a good idea to run the install and uninstall with logging enabled first, before we jump to conclusions.
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
H4nd0
Posts: 92
Joined: Thu Nov 09, 2006 8:16 am
Location: Sydney, AU
Contact:

Post by H4nd0 »

It would appear the installer is creating it's own registry keys and the creation of these keys is not even logged (!!!) ... it looks like the installer is grabbing something out of the project settings.

So here on install it's creating (I don't know where this is happening):

SOFTWARE\\FireDaemon Technologies Limited\\FireDaemon\\1.9

and then in the MSI code I create keys under here (which is where I want them):

SOFTWARE\\FireDaemon Technologies\\FireDaemon\\1.9

When the uninstall happens the former is being orphaned. Here's the logs (install then uninstall for all RegAdd and RegDelete events):

MSI (s) (B4:7C) [18:59:42:702]: Executing op: RegOpenKey(Root=-2147483646,Key=SOFTWARE\\FireDaemon Technologies\\FireDaemon\\1.9,,BinaryType=0)
MSI (s) (B4:7C) [18:59:42:718]: Executing op: RegAddValue(Name=Product,Value=Pro,)
MSI (s) (B4:7C) [18:59:42:718]: Executing op: RegAddValue(Name=InstallationDir,Value=C:\\Program Files\\FireDaemon,)
MSI (s) (B4:7C) [18:59:42:718]: Executing op: RegAddValue(Name=Control,Value=#0,)
MSI (s) (B4:7C) [18:59:42:718]: Executing op: RegAddValue(Name=VersionCheck,Value=#0,)
MSI (s) (B4:7C) [18:59:42:733]: Executing op: RegOpenKey(Root=-2147483646,Key=SYSTEM\\CurrentControlSet\\Services\\Eventlog\\Application\\FireDaemon,,BinaryType=0)
MSI (s) (B4:7C) [18:59:42:733]: Executing op: RegAddValue(Name=EventMessageFile,Value=C:\\Program Files\\FireDaemon\\Core.dll,)
MSI (s) (B4:7C) [18:59:42:733]: Executing op: RegAddValue(Name=TypesSupported,Value=#7,)

----------------------------------------------------

MSI (s) (B4:D4) [19:01:48:389]: Executing op: ActionStart(Name=RemoveRegistryValues,Description=Removing system registry values,Template=Key: [1], Name: [2])
MSI (s) (B4:D4) [19:01:48:389]: Executing op: ProgressTotal(Total=6,Type=1,ByteEquivalent=13200)
MSI (s) (B4:D4) [19:01:48:389]: Executing op: RegOpenKey(Root=-2147483646,Key=SOFTWARE\\FireDaemon Technologies\\FireDaemon\\1.9,,BinaryType=0)
MSI (s) (B4:D4) [19:01:48:389]: Executing op: RegRemoveValue(Name=Product,Value=[PWRSFARIEEMTCOLISREEON9PODCTROF0_3],)
MSI (s) (B4:D4) [19:01:48:389]: Executing op: RegRemoveValue(Name=InstallationDir,Value=[PWRFAIEEMTCOLISREEO9ITLTIDRRGDR0_3],)
MSI (s) (B4:D4) [19:01:48:389]: Executing op: RegRemoveValue(Name=Control,Value=#[PWRSFARIEEMTCOLISREAEON9CNTOLFT0_3],)
MSI (s) (B4:D4) [19:01:48:405]: Executing op: RegRemoveValue(Name=VersionCheck,Value=#[PWRSFARIEEMTCOLISREEO9VSONHEK0T0_3],)
MSI (s) (B4:D4) [19:01:48:421]: Executing op: RegOpenKey(Root=-2147483646,Key=SYSTEM\\CurrentControlSet\\Services\\Eventlog\\Application\\FireDaemon,,BinaryType=0)
MSI (s) (B4:D4) [19:01:48:436]: Executing op: RegRemoveValue(Name=EventMessageFile,Value=[PWRSMRNNOSEEVLGLAFIENNMAFARIOLT0_3],)
MSI (s) (B4:D4) [19:01:48:436]: Executing op: RegRemoveValue(Name=TypesSupported,Value=#[PWRSMRNNOSEEVLGPLAIFIDENTESPOE70_3],)
MSI (s) (B4:D4) [19:01:48:452]: Executing op: ActionStart(Name=RemoveShortcuts,Description=Removing shortcuts,Template=Shortcut: [1])
MSI (s) (B4:D4) [19:01:48:468]: Executing op: SetTargetFolder(Folder=23\\FireDaemon Pro\\)
H4nd0
Posts: 92
Joined: Thu Nov 09, 2006 8:16 am
Location: Sydney, AU
Contact:

Post by H4nd0 »

Mate ... sorry :oops:

This was a bug in our product writing the reg keys in ... grrr.
MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Post by MichaelNesmith »

H4nd0 wrote:Mate ... sorry
Figured it had to be something like that :lol:
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
Post Reply