[英]How come C++ project in Visual Studio Community 2015 only contain Universal Apps?
First, let me show you what I have.. 首先,让我告诉你我有什么..
Visual Studio Community 2015 installed with customization as follows.. Visual Studio Community 2015安装了自定义如下..
Windows 10 Home (x64) Windows 10 Home(x64)
I tried creating C++ project with Win32 and standard C++11 support but I couldn't find any under "File > New > Project > Installed > Templates > Visual C++ > Windows". 我尝试使用Win32和标准C ++ 11支持创建C ++项目,但我在“文件>新建>项目>安装>模板> Visual C ++> Windows”下找不到任何项目。 (Universal Windows App is the only option here ...) (通用Windows应用程序是这里唯一的选择...)
I wish that the subpaths under my "File > New > Project > Installed > Templates > Visual C++ > Windows" have all three items that Visual C# and Basic already have underneath ("Universal", "Windows 8", "Classic Desktop"). 我希望我的“File> New> Project> Installed> Templates> Visual C ++> Windows”下的子路径包含Visual C#和Basic已经拥有的所有三个项目(“Universal”,“Windows 8”,“Classic Desktop”) 。 To be more specific, I wish my "Visual C++ > Windows" to look like this.. 更具体地说,我希望我的“Visual C ++> Windows”看起来像这样。
I know that I can code Win32/C++ using "Universal Windows Apps" template but Win32 support is limited and it comes with bunch of .Net stuff that I don't need. 我知道我可以使用“通用Windows应用程序”模板对Win32 / C ++进行编码,但Win32支持是有限的,它带有一堆我不需要的.Net内容。 Please don't get me wrong, I do love .Net and WPF and I myself was once a C# programmer (WinForm in particular) and I think of .Net to be the future of Windows development but right now I need to start with empty project with Win32/C++ support. 请不要误会我的意思,我喜欢.Net和WPF,我自己曾经是C#程序员(尤其是WinForm),我认为.Net是Windows开发的未来,但现在我需要从空开始具有Win32 / C ++支持的项目。
Is this problem confined to Community version only? 这个问题仅限于社区版吗? (anyone tried VS2015 Pro/Ent ? please let me know) (有人试过VS2015 Pro / Ent吗?请告诉我)
EDIT: Definitely can't be a solution to this problem.. but I found that I can circumvent the problem as below: 编辑:绝对不能解决这个问题..但我发现我可以绕过这个问题如下:
Here's how it works. 这是它的工作原理。 Instead of searching for templates in "Installed > Visual C++ > Windows", I just go to "Installed > Samples > Visual C++ > Desktop" and Hurray! 我没有在“已安装> Visual C ++> Windows”中搜索模板,而是转到“已安装>示例> Visual C ++>桌面”和Hurray! I see a Win32 "C++ UTF-8 Conversion Helpers" sample. 我看到了Win32“C ++ UTF-8转换助手”示例。 I'll just use it to create projects and then discard anything unnecessary to make it empty. 我只是用它来创建项目,然后丢弃任何不必要的东西以使它变空。 One hell of a pathetic approach just to get an empty C++ project :( 为了得到一个空的C ++项目,一个可悲的方法的地狱:(
EDIT: I posted the same question on Microsoft Developer Network. 编辑:我在Microsoft Developer Network上发布了相同的问题 。 After another day of trials and errors, this is the furthest I went. 经过一天的试验和错误, 这是我走得最远的。 Still no sign of "Classic Desktop" under C++ C ++下仍然没有“经典桌面”的迹象
Finally, I found an answer to this problem.... 最后,我找到了这个问题的答案....
I was so stupid to keep on launching vs-community using the wrong shortcut. 我是如此愚蠢,继续使用错误的快捷方式启动vs-community。
If you want to see all the C++ templates (including win32,MFC,ATL,...), you must use the shortcut "Visual Studio 2015" not the "Blend for Visual Studio 2015" ( screenshot ) 如果要查看所有C ++模板(包括win32,MFC,ATL等),则必须使用快捷方式“Visual Studio 2015”而不是“Blend for Visual Studio 2015”( 屏幕截图 )
There are two shortcuts after you install Visual Studio Community 2015. As you see , they each point to the different target . 安装Visual Studio Community 2015后有两个快捷方式。如您所见 ,它们各自指向不同的目标 。 So you need to use the shortcut that runs "devenv.exe" not the "Blend.exe". 因此,您需要使用运行“devenv.exe”而不是“Blend.exe”的快捷方式。
But its strange that the first launch after the ISO installation launches " devenv.exe " but the web installer(vs_community.exe) launches "Blend.exe". 但奇怪的是, ISO安装后首次启动“ devenv.exe ”,但Web安装程序(vs_community.exe)启动“Blend.exe”。
I guess I'm the only one here who made such a stupid mistake. 我想我是这里唯一犯过这么愚蠢错误的人。 May be I should delete this question if not so many find it useful. 可能是我应该删除这个问题,如果没有那么多人发现它有用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.