Contextual Menu to a Specific Folder

让人想犯罪 __ 提交于 2019-12-11 01:25:13

问题


I have read how to add a contextual menu though registry to all files or files according the extension. But how can I add a contextual menu that will work ONLY on files of a specific folder (for example on files of folder C:\contmenu)?

Can this be done?

Thanks a lot.


回答1:


If you're implementing a context menu shell extension, you get the path of the item in your IShellExtInit::Initialize() method. Then you can decide depending on the path whether to add your entries to the context menu or not.

It's not possible to register an extension just for a specific path though.



来源:https://stackoverflow.com/questions/9064272/contextual-menu-to-a-specific-folder

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