简体   繁体   English

Visual Studio 2019 社区版是否支持 MVC 5 项目?

[英]Does Visual Studio 2019 community edition support MVC 5 projects?

I wanted to start an MVC 5 project to follow a course, so I went to the Tools > Get Tools and Features.我想开始一个 MVC 5 项目来学习一门课程,所以我去了工具 > 获取工具和功能。 I can only see MVC 4 in the Individual components tab.我只能在单个组件选项卡中看到 MVC 4。

Does it mean I need to install different version of Visual Studio?这是否意味着我需要安装不同版本的 Visual Studio?

It will come in as a nuget package ( System.Web.Mvc ) and not the Tools and Features installer of VS.它将以 nuget package ( System.Web.Mvc ) 的形式出现,而不是 VS 的工具和功能安装程序。

You'll require at least version 4.52 of .NET Framework (and I think) it would default to MVC 5.x by default (I could be wrong) but you can upgrade the nuget package manager and update it manually.您至少需要 .NET 框架的 4.52 版本(我认为)默认情况下它会默认为 MVC 5.x(我可能是错的),但您可以升级 nuget ZEFE90A8E604A7C840E88D03A6 并手动更新它。

You don't have to install any nuget package for that.您不必为此安装任何 nuget package。 Just create a new project in vs 2019 community and on project template selection page, select "ASP.NET Web Application (.Net Framework)".只需在 vs 2019 社区和项目模板选择页面上创建一个新项目 select "ASP.NET Web Application (.Net Framework)"。 It will default to MVC5 project.它将默认为 MVC5 项目。

Project Template Selection window项目模板选择 window

You can check the mvc version later in web.config file.您可以稍后在 web.config 文件中查看 mvc 版本。

<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35"/>
    <bindingRedirect oldVersion="1.0.0.0-5.2.7.0" newVersion="5.2.7.0"/>
  </dependentAssembly>

here you can see assembly name and its version.在这里您可以看到程序集名称及其版本。

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

相关问题 CS1729“MyNavigationPage”不包含带 1 个参数的构造函数 --&gt; 在 Visual Studio 2019 社区版中 - CS1729 'MyNavigationPage' does not contain a constructor that takes 1 arguments --> in visual studio 2019 community edition Visual Studio社区是否支持“添加为链接”? - Does Visual Studio Community support “Add as Link”? 如何在 Visual Studio 2019 社区版中将我的发布项目转换为安装程序? - How do I turn my release project into an installer in Visual Studio 2019 Community Edition? 无法在 Visual Studio 2019 社区版 16.7.2 中使用外部应用程序调试 c# dll 项目 - Unable to debug c# dll project with an external app in Visual Studio 2019 Community edition 16.7.2 Visual Studio社区版中的连接字符串 - connection string in visual studio community edition Visual Studio 2015社区版在启动时崩溃 - Visual Studio 2015 community edition crashes at startup 评论选择在 Visual Studio 社区 2019 中不起作用 - Comment selection not working in visual studio community 2019 Visual Studio 社区 2019 更新影响 Xamarin - Visual Studio Community 2019 Update affects Xamarin Visual Studio社区版Windows Phone应用程序丢失 - Visual Studio community edition windows phone app missing 如何为Visual Studio 2015 Community Edition使用Type.GetTypeFromProgID() - How to use Type.GetTypeFromProgID() for Visual Studio 2015 Community Edition
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM