sulfericacid has asked for the wisdom of the Perl Monks concerning the following question:
This code produces no error like it originally did when it told me the file could not be found. It prints "done" but when I go back into regedit, the folder/key is still sitting there smiling at me.
The key MyWay DOES exist, I checked it a dozen times. The original thought was we couldn't delete keys that had subkeys, but according to the example they use, it sounds like you can"#!/usr/bin/perl use warnings; use strict; use Win32::TieRegistry( Delimiter=>"/", ArrayValues=>0 ); my $myway= delete $Registry->{"HKEY_LOCAL_MACHINE/SOFTWARE/MyWay/"}; print "Done";
I'm on WinXP for those who are interested. Thank you for your help!Deleting a key WARNING: The following code will delete all information about the curr +ent user's tip preferences. Actually executing this command would pro +bably cause the user to see the Welcome screen the next time they log + in and may cause more serious problems. This statement is shown as a +n example only and should not be used when experimenting. $tips= delete $Registry->{"CUser/Software/Microsoft/Windows/" . "CurrentVersion/Explorer/Tips/"};
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Removing keys in the registry
by davidj (Priest) on Jun 04, 2004 at 00:46 UTC | |
|
Re: Removing keys in the registry (code)
by tye (Sage) on Jun 04, 2004 at 16:47 UTC | |
by ZlR (Chaplain) on Aug 25, 2005 at 09:04 UTC | |
by tye (Sage) on Aug 25, 2005 at 22:38 UTC | |
by ZlR (Chaplain) on Sep 02, 2005 at 08:50 UTC | |
by tye (Sage) on Sep 02, 2005 at 22:51 UTC | |
|
Re: Removing keys in the registry
by baruch (Beadle) on Jun 04, 2004 at 04:41 UTC | |
by tye (Sage) on Jun 04, 2004 at 07:18 UTC |