如何显示从C#应用程序的Windows资源管理器右键菜单? [英] How do you show the Windows Explorer context menu from a C# application?
本文介绍了如何显示从C#应用程序的Windows资源管理器右键菜单?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个文件在上市我的申请,我想,让人们在一个项目单击鼠标右键,显示Windows资源管理器上下文菜单。我假设我需要请使用IContextMenu接口,但我真的不知道从哪里开始。
I have a file listing in my application and I would like to allow people to right-click on an item and show the Windows Explorer context menu. I'm assuming I would need to use the IContextMenu interface, but I'm not really sure where to start.
推荐答案
有一个非常好的教程(虽然C ++)约在11份关于Raymond Chen的博客托管的IContextMenu(按顺序):
There's a very good tutorial (albeit in C++) about hosting an IContextMenu on Raymond Chen's blog in 11 parts (in order):
- Initial foray
- Displaying the context menu
- Invocation location
- Key context
- Handling menu messages
- Displaying menu help
- Invoking the default verb
- Optimizing for the default command
- Adding custom commands
- Composite extensions - groundwork
- Composite extensions - composition
这篇关于如何显示从C#应用程序的Windows资源管理器右键菜单?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文