操作步骤:
测试环境:Windows 10 预览版 10240版本 提示:修改注册表有风险,请提前备份数据并在专业人士指导下慎重操作。 1、 新建TXT文档,将下面代码复制到记事本里保存。 $regkey = "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" $name = "AppsUseLightTheme" $exists = Get-ItemProperty -Path "$regkey" -Name "$name" -ErrorAction SilentlyContinue If (($exists -ne $null) -and ($exists.Length -ne 0)) { Remove-ItemProperty -Path $regkey -Name $name }else{ New-ItemProperty -Path $regkey -Name $name -Value 0 } 2、 将txt文档后缀改为ps1。在弹出的对话框中点击“是”。 
3、 右键单击ps1文件,选择“使用PowerShell运行”即可切换到夜间模式。再次运行可恢复。 
4、此时打开设置、计算器等界面,界面已经变为夜间模式了。
备注:
附件为已经做好的工具,可以下载后解压,直接双击运行。
附加文档1:
夜间模式.zip |