右键菜单 显示/隐藏文件扩展名 隐藏文件扩展名

@echo off

title 右键菜单 显示/隐藏文件扩展名

if not exist "%windir%SuperHidden.vbs" goto setup

reg delete "HKCRCLSID{00000000-0000-0000-0000-000000000012}" /f >nul 2>nul

del /f /q "%windir%SuperHidden.vbs" >nul 2>nul

echo.&echo 显示文件扩展名 右键卸除完毕。

exit

:setup

>"%windir%SuperHidden.vbs" echo Dim WSHShell

>>"%windir%SuperHidden.vbs" echo Set WSHShell = WScript.CreateObject("WScript.Shell")

>>"%windir%SuperHidden.vbs" echo WSHShell.RegWrite "HKCRCLSID{00000000-0000-0000-0000-000000000012}InstanceInitPropertyBagCLSID", "{13709620-C279-11CE-A49E-444553540000}", "REG_SZ"

>>"%windir%SuperHidden.vbs" echo WSHShell.RegWrite "HKCRCLSID{00000000-0000-0000-0000-000000000012}InstanceInitPropertyBagmethod", "ShellExecute", "REG_SZ"
右键菜单 显示/隐藏文件扩展名 隐藏文件扩展名

>>"%windir%SuperHidden.vbs" echo if WSHShell.RegRead("HKCUSoftwareMicrosoftWindowsCurrentVersionExplorerAdvancedHideFileExt") = 0 then

>>"%windir%SuperHidden.vbs" echo WSHShell.RegWrite "HKCUSoftwareMicrosoftWindowsCurrentVersionExplorerAdvancedHideFileExt", "1", "REG_DWORD"

>>"%windir%SuperHidden.vbs" echo WSHShell.RegWrite "HKCRCLSID{00000000-0000-0000-0000-000000000012}InstanceInitPropertyBagcommand", "显示文件扩展名", "REG_SZ"

>>"%windir%SuperHidden.vbs" echo WSHShell.SendKeys "{F5}+{F10}e"

>>"%windir%SuperHidden.vbs" echo else

>>"%windir%SuperHidden.vbs" echo WSHShell.RegWrite "HKCUSoftwareMicrosoftWindowsCurrentVersionExplorerAdvancedHideFileExt", "0", "REG_DWORD"

>>"%windir%SuperHidden.vbs" echo WSHShell.RegWrite "HKCRCLSID{00000000-0000-0000-0000-000000000012}InstanceInitPropertyBagcommand", "隐藏文件扩展名", "REG_SZ"

>>"%windir%SuperHidden.vbs" echo WSHShell.SendKeys "{F5}+{F10}e"

>>"%windir%SuperHidden.vbs" echo end if

>>"%windir%SuperHidden.vbs" echo Set WSHShell = Nothing

>>"%windir%SuperHidden.vbs" echo WScript.Quit(0)

reg export "HKCUSoftwareMicrosoftWindowsCurrentVersionExplorerAdvanced" "%temp%__.reg" >nul

for /f "tokens=2 delims==" %%. in ('find/i "HideFileExt" "%temp%__.reg"') do set v=%%~.

del "%temp%__.reg"

set v=%v:~-1%

if %v% equ 0 set vv=隐藏文件扩展名

if %v% equ 1 set vv=显示文件扩展名

>"%temp%_.reg" echo REGEDIT4

>>"%temp%_.reg" echo [HKEY_CLASSES_ROOTDirectoryBackgroundshellexContextMenuHandlersSuperHidden]

>>"%temp%_.reg" echo @="{00000000-0000-0000-0000-000000000012}"

>>"%temp%_.reg" echo [HKEY_CLASSES_ROOTCLSID{00000000-0000-0000-0000-000000000012}InProcServer32]

>>"%temp%_.reg" echo @=hex(2):25,53,79,73,74,65,6d,52,6f,6f,74,25,5c,73,79,73,74,65,6d,33,32,5c,73,

>>"%temp%_.reg" echo 68,64,6f,63,76,77,2e,64,6c,6c,00

>>"%temp%_.reg" echo "ThreadingModel"="Apartment"

>>"%temp%_.reg" echo [HKEY_CLASSES_ROOTCLSID{00000000-0000-0000-0000-000000000012}Instance]

>>"%temp%_.reg" echo "CLSID"="{3f454f0e-42ae-4d7c-8ea3-328250d6e272}"

>>"%temp%_.reg" echo [HKEY_CLASSES_ROOTCLSID{00000000-0000-0000-0000-000000000012}InstanceInitPropertyBag]

>>"%temp%_.reg" echo "method"="ShellExecute"

>>"%temp%_.reg" echo "Param1"="SuperHidden.vbs"

>>"%temp%_.reg" echo "CLSID"="{13709620-C279-11CE-A49E-444553540000}"

>>"%temp%_.reg" echo "command"="%vv%"

regedit /s "%temp%_.reg"

del /f /q "%temp%_.reg"

echo.&echo %vv% 已添加到右键。

exit

  

爱华网本文地址 » http://www.aihuau.com/a/25101013/164740.html

更多阅读

右键菜单中没有RAR压缩项怎么办 360压缩右键菜单删除

右键菜单中没有RAR压缩项怎么办——简介 安装了RAR压缩后,就会右键菜单中显示压缩项,对于压缩与解压文件都很方便,但是由于其它软件的安装,把右键菜单中的压缩项给弄没了,这该怎么办啊,本篇就教大家如何处理这个问题。详细方法请阅读以下

360如何管理鼠标右键菜单 鼠标右键新建菜单管理

很多时候我们用鼠标右键点击某个文件的时候,列表中会有很多选项,部分选项是系统默认的,而部分选项是安装某些软件的时候附加上去的。对于一些不常用的内容,可以通过右键菜单管理把它去掉。或者对于一些常用的功能,可以增加上。360鼠标右

删除右键菜单中多余项 怎么清除右键多余菜单

开始——运行“打开”框中键入“regedit”删除右键菜单中多余项——工具/原料电脑左下角:开始——运行“打开”框中键入“regedit”删除右键菜单中多余项——步骤/方法删除右键菜单中多余项 1、一: 开始——运行里面输入: regsvr32 /u

声明:《右键菜单 显示/隐藏文件扩展名 隐藏文件扩展名》为网友时光瘦了分享!如侵犯到您的合法权益请联系我们删除