Click here to return home   Click here to visit the Tweaks.com Network


Collapse Regedit Tree Without Disabling
Posted 12/12/2002 by TweakXP Member

RegEdit annoyingly remembers the last key you viewed and then the next time you use the application, it is expanded to that section. There are other tweeks that change the permissions on the Regedit applet in the registry to deny access.

That does work. However, in the process, you lose the ability to create favorites.

A few lines of code solves the problem. You can then create a shortcut to the .vbs file and change the icon to the regedit icon and put it on the desktop, add it to a start menu, whatever. Just put these few lines in a text editor and save as the xxxxxx.vbs.

REM ***********************************************

Dim objShell, RegKey, Q

Set objShell = CreateObject("WScript.Shell")

            strQuote = chr(34)      

RegKey = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Applets\Regedit"

RegKey = RegKey & "\LastKey"

objShell.RegWrite RegKey, ""

objShell.Run "regedit"

REM ***********************************************



Related Advertisement

Free Computer Magazines for TweakXP.com Visitors!
InfoWorld Making the right technology buying decisions is more important to business success than ever. That's why InfoWorld is dedicated to helping IT professionals get technology right. eWeek is the essential weekly technology information source for builders of e-business.
Other Titles: RCR Wireless, Network World, InfoWorld, Information Week, CRN Magazine, BaseLine Magazine, Many More Free Magazines!

 


© 2001-2009 Advanced PC Media LLC, All rights reserved.
TweakXP.com® is a registered trademark of Advanced PC Media LLC.

Microsoft, Windows and Windows XP are registered trademarks of Microsoft
Corporation.  Microsoft Corporation in no way endorses or is affiliated with TweakXP.com®.
All other products mentioned are registered trademarks and/or trademarks of their respective companies.