' ============================================================
' CheckLightModeStatus.vbs
'
' Checks whether "Enable Light Mode" is currently applied.
'
' Usage: cscript CheckLightModeStatus.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