返回列表 发帖

100元求助写批处理添加组策略设置

本帖最后由 klamelin 于 2020-11-10 14:48 编辑

有偿100元求助写批处理,添加组策略设置控制面板隐藏文件

本人已经在组策略操作成功,在控制面板内隐藏文件链接。要写批处理自动操作这过程,且不显示过程和结果提示。这个批处理,我要加到我原来某个bat文件里。

已完成。

@echo off
cd /d "%~dp0"
>tmp.reg (
    for /f "skip=18 delims=" %%L in (%~snx0) do (
        echo;%%L
    )
)
echo on
reg delete HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\DisallowCpl /f
regedit /s tmp.reg
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\DisallowCpl /v 1 /t reg_sz /d "Microsoft.Fonts" /f
del tmp.reg
REM gpupdate /force
exit
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer]
"DisallowCpl"=dword:00000001
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\DisallowCpl]
"1"="Microsoft.Fonts"COPY

TOP

@echo off
set "regpath=HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer"
reg add "%regpath%" /v DisallowCpl /t REG_DWORD /d 1 /f
reg add "%regpath%\DisallowCpl" /v 1 /t REG_SZ /d "Microsoft.Fonts" /f
gpupdate /force
pause
exitCOPY
提供bat代写,为你省时省力省事,支付宝扫码头像支付
微信: unique2random

TOP

本帖最后由 yhcfsr 于 2020-11-5 19:34 编辑
@echo off
%1 start "" mshta vbscript:createobject("shell.application").shellexecute("""%~0""","::",,"runas",1)(window.close)&exit
reg add HKEY_USERS\S-1-5-21-210385433-1441970752-1775599064-1001\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer /v DisallowCpl /t REG_DWORD /d 0x00000001 /f
reg add HKEY_USERS\S-1-5-21-210385433-1441970752-1775599064-1001\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\DisallowCpl /v 1 /t REG_SZ /d Microsoft.Fonts
gpupdate /forceCOPY
QQ 33892006

TOP

返回列表