Monday 2 July 2018

windows 7 - Enable/disable the "Show hidden files" setting from the command line


In Windows Explorer, the setting Show hidden files, folders and drives can be enabled and disabled under Organise > Folder and search options > View.


Is there another, quicker way to enable/disable this setting? Something via the command line would be ideal, but I'm open to all suggestions that are quicker or less cumbersome.



Answer



These settings are in the Registry at this key:


HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced

To show hidden items, set Hidden to 1 (to hide them, set it to 2). To show system/super-hidden items, set ShowSuperHidden to 1 (0 to hide). Since we're fiddling with the Registry directly, Explorer has to be restarted.


To accomplish all of that and enable viewing of everything, you can use these batch commands:


reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced /v Hidden /t REG_DWORD /d 1 /f
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced /v ShowSuperHidden /t REG_DWORD /d 1 /f
powershell -c gps 'explorer' ^| stop-process

If you prefer to avoid PowerShell, this should also work to kill Explorer:


taskkill /im explorer.exe /f

If Explorer doesn't automatically relaunch on your system, simply run explorer to get your taskbar back.


No comments:

Post a Comment

Where does Skype save my contact's avatars in Linux?

I'm using Skype on Linux. Where can I find images cached by skype of my contact's avatars? Answer I wanted to get those Skype avat...