📜 VBScript (WSH)

Check "Enable Dark Mode" Status (VBScript)

Reads the registry value behind the "Enable Dark Mode" tweak to confirm whether it's applied.

By WindowsScripting.com · 690 B
CheckDarkModeStatus.vbs
' ============================================================
' CheckDarkModeStatus.vbs
'
' Checks whether "Enable Dark Mode" is currently applied.
'
' Usage: cscript CheckDarkModeStatus.vbs
' ============================================================

Option Explicit

Dim objShell, currentValue
Set objShell = CreateObject("WScript.Shell")

On Error Resume Next
currentValue = objShell.RegRead("HKCU\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize\AppsUseLightTheme")

If Err.Number <> 0 Then
    WScript.Echo "'AppsUseLightTheme' is not set (using the Windows default)."
Else
    WScript.Echo "Current value of 'AppsUseLightTheme': " & currentValue
End If
On Error Goto 0