farag2 / Sophia-Script-for-Windows

:zap: The most powerful PowerShell module on GitHub for fine-tuning Windows 10 & Windows 11
MIT License
7.41k stars 577 forks source link

add function to hide User Folders from This PC #535

Closed Obegg closed 8 months ago

Obegg commented 9 months ago

Add a function to Sophia Script to remove User Folders from This PC image

Windows Registry Editor:

; Documents Folder
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FolderDescriptions\{f42ee2d3-909f-4907-8871-4c22fc0bf756}\PropertyBag]
"ThisPCPolicy"="Hide"

; Pictures Folder
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FolderDescriptions\{0ddd015d-b06c-45d5-8c4c-f59713854639}\PropertyBag]
"ThisPCPolicy"="Hide"

; Videos Folder
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FolderDescriptions\{35286a68-3c57-41a1-bbb1-0eae73d76c95}\PropertyBag]
"ThisPCPolicy"="Hide"

; Downloads Folder
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FolderDescriptions\{7d83ee9b-2244-4e70-b1f5-5393042af1e4}\PropertyBag]
"ThisPCPolicy"="Hide"

; Music Folder
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FolderDescriptions\{a0c69a99-21c8-4671-8703-7934162fcf1d}\PropertyBag]
"ThisPCPolicy"="Hide"

; Desktop Folder
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FolderDescriptions\{B4BFCC3A-DB2C-424C-B029-7FE99A87C641}\PropertyBag]
"ThisPCPolicy"="Hide"
farag2 commented 8 months ago

The function is done. Soon a new script version will be released. 🐱

Obegg commented 8 months ago

Thank you!

Do you think "Quick Actions from Notification Center" feature should be added? C6E75DAEC36A To hide it I created a .reg file with the following:

; Unpin Quick Actions from Notification Center
[HKEY_CURRENT_USER\Control Panel\Quick Actions\Control Center\Unpinned]
"Microsoft.QuickAction.ScreenClipping"=hex(0):
"Microsoft.QuickAction.Project"=hex(0):
"Microsoft.QuickAction.AllSettings"=hex(0):
"Microsoft.QuickAction.AvailableNetworks"=hex(0):
"Microsoft.QuickAction.Location"=hex(0):
"Microsoft.QuickAction.QuietHours"=hex(0):
"Microsoft.QuickAction.Connect"=hex(0):
"Microsoft.QuickAction.Vpn"=hex(0):
"Microsoft.QuickAction.BlueLightReduction"=hex(0):
"Microsoft.QuickAction.WiFi"=hex(0):
"Microsoft.QuickAction.AirplaneMode"=hex(0):
"Microsoft.QuickAction.NearShare"=hex(0):
"Microsoft.QuickAction.MobileHotspot"=hex(0):
"Microsoft.QuickAction.Bluetooth"=hex(0):
farag2 commented 8 months ago

Oh, no. Please. Nobody cares about that icons)

Obegg commented 8 months ago

understandable-have-nice-day

farag2 commented 8 months ago

Better find how to expand Action Center. It's collapsed bu default. Will be much useful)

Obegg commented 8 months ago

Just for clarification - you mean this? Action-Center-icons-expand-collapse

farag2 commented 8 months ago

Yes!

Obegg commented 8 months ago

Well, I did try, I've used RegistryChangesView to see what changes when I expand or collapse the action center, and seems like the major one is HKEY_CURRENT_USER\Control Panel\Quick Actions\Control Center\QuickActionsStateCapture with Toggles so that instead of showing 4 entries it shows 8 entries for example, but I tested it and it doesn't seem to change anything, I even tried with PowerShell instead of .reg file and couldn't get it to change even after restart to the machine. Any ideas to continue with this?

farag2 commented 8 months ago

Well, OK I will check by myself)

farag2 commented 8 months ago

It's stored in a binary format somewhere in HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\CloudStore\Store\DefaultAccount\Current\default$windows.data.controlcenter.uistate\windows.data.controlcenter.uistate. I give up...

Obegg commented 8 months ago

Nice try though, good effort