PDA

View Full Version : Deleting HKCR key


pliant
05-08-2006, 10:23 AM
Hi,
I'm trying to use vbscript to delete a registry key from HKCR. I can delete it manually in, however, when I run the script I keep on receiving the following error message:

-2147024894 - Unable to remove registry key "HKCR\*\shellex\ContextMenuHandlers\{c574f540-cdcd-11cf-8ea5-444554530000}\"

Here's the code:
WSHShell.RegDelete "HKCR\*\shellex\CopyHookHandlers\EntrustCopyHook\"

I've also tried:
WSHShell.RegDelete "HKLM\Software\Classes\*\shellex\CopyHookHandlers\EntrustCopyHook\"

but receive the same error message. Is it possible to delete HKCR keys using vbscript?