Search the Community
Showing results for tags 'RegDelete()'.
-
Under a 64-bit OS, do I always have to call RegDelete() with both the 64-bit reg path and the regular reg path if I want to delete a reg key or value? I've been insulted here for writing more than a dozen or so words in these posts, but I don't know any other way to explain myself, so here I go again (please be kind): I've been struggling with the fact that the scripts I've recently written to delete some registry keys on a 64-bit Windows 7 Pro system don't end up actually deleting the keys in question. In these scripts, I've always made sure to suffix the reg root key with "64", as emphasized in the RegDelete() help file. For instance, to delete a key starting with "HKU", I've made sure the reg path starts with "HKU64". I scrupulously check the return codes after every function, and certainly did so with the RegDelete() calls, but while there was never any error, the keys in question were always still there when I examined them using my 64-bit registry editor (Registrar Registry Manager 64-bit), using the standard key paths! After repeatedly failing to actually delete the keys in question, I modified the scripts to call RegDelete() with both "HKU64..." -and- "HKU...", and lo and behold, it worked! The keys were actually gone. Questions: (1): Is this something everyone already knows? If so, where is it explained? (2): Is it always true under a 64-bit OS that one must always delete both sets of keys? Or is it necessary sometimes but not others? Please help me understand this. (Misc Info: I have UAC disabled, and I always run with Administrator privelege. All the reg keys and values I wish to delete are in the "HKU/HKU64" or "HKCU/HKCU64" trees.) Thanks!