jed*_*der 5 windows registry contextmenu
添加Windows外壳上下文菜单,让我们说的.txt文件-如果.txt 扩展的HKEY_CLASSES_ROOT(或者HKEY_CURRENT_USER\Software\Classes,其实并不重要)的默认值(文件类型)txtfile-您添加的命令HKEY_CLASSES_ROOT\txtfile\shell\yourcommand(和命令本身HKEY_CLASSES_ROOT\txtfile\shell\yourcommand\command,当然)你走了.
但是,假设.txt 扩展名具有默认值Notepad++_file.Notepad++_file可能是许多其他扩展的文件类型,因此如果您将命令添加到,则此命令将针对与Notepad ++关联的每个扩展名显示.HKEY_CLASSES_ROOT\Notepad++_file
所以,问题是:如果可能的话,如何在不更改文件类型的情况下为只有一个特定的EXTENSION添加菜单条目?
PS:我不想只复制文件类型,因为将来对原始文件类型的更改不会影响重复的文件类型.
Aze*_*edo 15
干得好:
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\*\shell\your custom app]
@="Open with your custom app"
"icon"="C:\\Windows\\notepad.exe,0"
"AppliesTo"=".nfo"
[HKEY_CLASSES_ROOT\*\shell\your custom app\command]
@="C:\\Windows\\notepad.exe \"%1\""
Run Code Online (Sandbox Code Playgroud)
这条线"AppliesTo"=".nfo"就行了.
在Windows 10上完美运行.
它适用于每个文件扩展名,无论是否存在与该扩展名相关联的应用程序.这样做可以减少入侵,并在注册表中留下非常小的空间.
比较仅针对特定文件类型的"添加"菜单项到Windows上下文菜单
编辑:
如果要将该命令应用于多个扩展,请使用:
"AppliesTo"="System.FileName:\"*.nfo\" OR System.FileName:\"*.log\""
Run Code Online (Sandbox Code Playgroud)
图片来源:https://superuser.com/questions/183785/windows-7-context-menu-for-folders-if-folder-contains-certain-filetypes
| 归档时间: |
|
| 查看次数: |
3261 次 |
| 最近记录: |