在Visual Studio 2015中创建一个空的MVC项目 [英] Creating an Empty MVC Project in Visual Studio 2015

查看:164
本文介绍了在Visual Studio 2015中创建一个空的MVC项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用VS 2015 Enterprise,并且试图创建一个空的MVC项目.

I am using VS 2015 Enterprise and I'm trying to create an empty MVC project.

我通过右键单击解决方案进入添加|新项目..."对话框.然后,从左侧列表中选择"Web",然后选择"ASP.NET Web Application",如下所示:

I go into the "Add | New Project..." dialog by right-clicking on the solution. I then select "Web" from the list along the left side and select "ASP.NET Web Application" as shown here:

接下来,以下对话框窗口打开,但"Web表单","MVC"和"Web API"的复选框均被禁用.有谁知道为什么他们被禁用以及如何启用它们?选择"Web API"或"Web应用程序"(而不是"Empty")不会更改复选框的状态,而是保持禁用状态.

Next, the following dialog window opens but the checkboxes for "Web Forms", "MVC" and "Web API" are all disabled. Does anyone know why they are disabled and how to enable them? Selecting "Web API" or "Web Application" (instead of "Empty") does not change the checkboxes' state -- they remain disabled.

如果我没记错的话,我曾经能够在VS 2013中创建一个空的MVC项目,没有问题.

If I recall correctly I used to be able to create an empty MVC project in VS 2013 with no problem.

推荐答案

您可以选择Empty template和MVC复选框选项,这将为您提供带有空Model,Views和Controller的MVC Web应用程序.

You can select Empty template along with MVC checkbox option which will give you MVC web application with empty Model, Views and Controller.

这篇关于在Visual Studio 2015中创建一个空的MVC项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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