41.4 Windows Code Snippets


Old Windows Taskbar Themes

RetroBar 🡵

Recommended from FinkThing

Update USB Drivers

Use Zadig 🡵.

Remove empty lines in a text file

Get-Content input.md | Where-Object { $_.Trim() -ne "" } | Set-Content output.md

Google Docs Markdown Linting Script

Script to remove empty lines from Google Docs Markdown

Restart Windows Audio Drivers

net stop audiosrv 
net stop AudioEndpointBuilder 
net start audiosrv 
net start AudioEndpointBuilder 

(Restart Windows Audio Drivers Powershell Script)

Send Numlock Key

(New-Object -ComObject WScript.Shell).SendKeys('{NUMLOCK}')

Enable Fast Alt-Tab

Navigate in the registry editor to

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer

Then:

  1. Right-click an empty space in the right-hand pane, select New, then DWORD (32-bit) Value.
  2. Name the new value exactly AltTabSettings (ensure no spaces and proper capitalization).
  3. Double-click AltTabSettings, change the Value data to 1, and click OK.
  4. Restart your computer (or open Task Manager, right-click Windows Explorer, and click Restart) for the changes to take effect.

Enable One Click Taskbar Window Activation

Navigate in the registry editor to

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

Then:

  1. Right-click in the right pane, select New > DWORD (32-bit) Value, and name it LastActiveClick.
  2. Double-click the newly created value and set its Value data to 1.
  3. Click OK to save the changes.
  4. Restart Explorer

Disable Windows Compatibility Telemetry

Windows Compatibility Telemetry can be responsible for intermittent high CPU usage. Here's how to disable it for better performance.

Navigate in the registry editor to

Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\compattelrunner.exe

You might have to create the compattelrunner.exe key.

Then, add a new value debugger and set it to C:\windows\system32\systray.exe

We'll have to see if this actually works.

Disable Extra Keypress on Login Screen

  1. Type WinKey + R, enter gpedit.msc & press Enter
  2. Navigate to Computer Configuration > Administrative Templates > Control Panel > Personalization
  3. Navigate to Do not display Lock Screen, right-click and go to Properties
  4. Set "Do not display the lock screen" to Enabled
  5. Reboot