|Perl Monk, Perl Meditation|
Unable to delete registry keys using Win32::TieRegistryby liverpole (Monsignor)
|on Sep 01, 2010 at 00:03 UTC||Need Help??|
liverpole has asked for the wisdom of the Perl Monks concerning the following question:
Greetings fellow monks,
I'm not sure if my problem is with my misunderstanding of how the registry works, or my somehow failing to use the Win32::TieRegistry module correctly. My intent is to delete the key 'HKEY_CLASSES_ROOT/Folder/shell/xyzzy_1' from the Windows XP registry on my laptop computer.
First of all, here's my code:
Prior to running the program, I created a registry key "HKEY_CLASSES_ROOT/Folder/shell/xyzzy_1", which along with the existing keys for the parent key look like this according to regedit (note my use of '###' for the folder icon):
When I run the program, the output I get is:
Can anyone suggest why the delete isn't apparently working (both from the error message, and the fact that it still shows up in the registry)? Am I missing some other step or steps? I'm using Win32::TieRegistry version 0.20 (which comes with my ActiveState Perl version 5.10.0); should I be updating to a later version of Win32::TieRegistry?
Thanks in advance for any help!