简体   繁体   English

解决方案资源管理器上下文菜单上的VS 2013(2015)扩展

[英]VS 2013 (2015) extension on solution explorer context menu

To add a context menu item to the solution explorer in Visual Studio, i can use the post Add context menu to VS 2010 solution explorer (display item on solution only) . 要将上下文菜单项添加到Visual Studio中的解决方案资源管理器,我可以使用将上下文菜单添加到VS 2010解决方案资源管理器(仅在解决方案上显示项目)

But is there a way to get the full filename of the selected solution? 但是有没有办法获取所选解决方案的完整文件名? And how to get the context menu to show only on project files and solution files so i can do somthing with the project file? 以及如何使上下文菜单仅在项目文件和解决方案文件上显示,以便我可以对项目文件进行处理?

To get the full filename of the currently opened solution you can use dte.Solution.FileName . 要获取当前打开的解决方案的完整文件名,可以使用dte.Solution.FileName

To add a menu command to a project in Solution Explorer you probably want to specify IDM_VS_CTXT_PROJNODE as the parent id. 要将菜单命令添加到解决方案资源管理器中的项目,您可能需要指定IDM_VS_CTXT_PROJNODE作为父ID。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Windows资源管理器VS解决方案文件的上下文菜单中的“构建”项? - “Build” item in Windows Explorer's context menu of a VS solution file? 如何修复 VS 2022 解决方案资源管理器中的上下文菜单 - How to fix context menu in Solution Explorer in VS 2022 解决方案资源管理器项目上下文菜单 - Solution Explorer Project Context Menu 在VS 2015扩展中,如何在解决方案资源管理器中获取所选对象? - In a VS 2015 extension, how can I get the selected object in the Solution Explorer? 如何在VS解决方案文件的Windows资源管理器的上下文菜单中“构建”项目? - How to "Build” item in Windows Explorer's context menu of a VS solution file? 在VS 2013中创建的BizTalk解决方案未在VS 2015中打开 - BizTalk solution created in VS 2013 not opening in VS 2015 Visual Studio 2015解决方案资源管理器操作:UIHierarchy与IVsHierarchy - Visual Studio 2015 solution explorer manipulation: UIHierarchy vs IVsHierarchy VS2015:如何隐藏解决方案资源管理器中的“参考”文件夹? - VS2015: How to hide the 'References' folder in solution explorer? 解决方案资源管理器中打开页面,而不是VS 2013中的主选项卡 - page opening in solution explorer instead of main tab in VS 2013 VS 2013-如何在解决方案资源管理器中跟踪文件更改? - VS 2013 - how to track file changes in solution explorer?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM