如何更改Visual Studio项目类型? [英] How to change a Visual Studio project type?

查看:244
本文介绍了如何更改Visual Studio项目类型?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最终发现,Visual Studio会跟踪您如何创建项目(换句话说,您最初选择的是哪个项目模板),并在以后根据该初始决定过滤选项.该信息作为< ProjectTypeGuids>保留在* .csproj文件中.元素.

I finally figured out that Visual Studio keeps track of how you create a project (in other words which project template you select initially) and filters your options later based on that initial decision. The information is kept in the *.csproj file as a <ProjectTypeGuids> element.

除了仅编辑* .csproj文件之外,还有没有正确"的方式来更改现有项目的项目类型?

Other than just editing the *.csproj file, is there a "right" way to change a project type for an existing project?

考虑到该设置的重要性,似乎在GUI中可以更改它,但是我找不到.谢谢!

Considering the significance of that setting it seems likely there's a place in the GUI to change it, but I couldn't find one. Thanks!

推荐答案

在Visual Studio中,项目类型作为GUID存储在.csproj XML文件中.您必须更改GUID才能定义所需的新项目类型.

In visual studio the project type is stored inside the .csproj XML file as GUID. You have to change the GUID to define the new project type you want.

检查 http://www.mztools.com/Articles/2008/MZ2008017.aspx 一些可用的GUID

check http://www.mztools.com/Articles/2008/MZ2008017.aspx for some of the availbale GUIDs

这篇关于如何更改Visual Studio项目类型?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆