How i can add a Entry to Shell Menu only on drive C:\?

蹲街弑〆低调 提交于 2019-12-24 02:44:27

问题


I need to add a Context Menu Item to Explorer Shell in Windows. This is easy doing by adding some Registgry Entry:

[HKEY_CLASSES_ROOT\Drive\shell\Disk cleanup\command]
@="cleanmgr.exe" 

but i like to add this entry only for drive C:\ or so. How i can do this?

Thanks!


回答1:


Try this. (Works on Windows 7 here.)

[HKEY_CLASSES_ROOT\Drive\shell\Disk cleanup\command]
@="cleanmgr.exe" 
"AppliesTo"="C:"

See Creating Shortcut Menu Handlers and Advanced Query Syntax for more about the AppliesTo field.

I don't see the exact usage above listed for drives but it seems to work and mimics other listed usages.



来源:https://stackoverflow.com/questions/27648332/how-i-can-add-a-entry-to-shell-menu-only-on-drive-c

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!