【发布时间】:2022-01-27 17:46:31
【问题描述】:
我在这里做错了吗?
我正在尝试在注册表中添加一个键及其值为 3 我收到以下错误。
REG ADD "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v "LogonsCount" /t REG_DWORD /d "3"
ERROR: Invalid key name.
Type "REG ADD /?" for usage.
我做错了什么?
【问题讨论】:
-
去掉冒号
:。 Reg.exe 不是 PowerShell -
我建议您在 PowerShell 中使用注册表 cmdlet,请参阅:docs.microsoft.com/powershell/scripting/samples/…
标签: powershell batch-file command registry regedit