@echo off
set Mainkey=HKEY_CURRENT_USER\SOFTWARE\Microsoft\InputMethod\Settings\CHS
for /f %%i in ('reg query %MainKey% /v "Enable Double Pinyin" ^| findstr /i "0x1"') do (set flg=%%i)
if not defined flg (
reg add %MainKey% /v "Enable Double Pinyin" /t REG_DWORD /d 0x1 /f
echo 已切换到双拼
) else (
reg add %MainKey% /v "Enable Double Pinyin" /t REG_DWORD /d 0x0 /f
echo 已切换到全拼
)
pause
标签:bat,Enable,全拼,MainKey%,echo,Pinyin,双拼
From: https://www.cnblogs.com/ainsliaea/p/17856192.html