[英]Compile errors when using C# 7 features in new VS Studio 2017 ASP.NET MVC 5.2.3 project
[英]VS 2019 - ASP.NET Core MVC web app (written in C#) : multiple errors on brand new project
使用 ASP.NET Core 5.0 MVC 的全新項目,編寫於 C#。
查看任何 default.cshtml 頁面時,錯誤列表 window 中出現多個錯誤。
但是,該項目仍然可以正常構建和運行。
錯誤包括:
- The name 'ViewData' does not exist in the current context.
- The name 'RenderBody' does not exist in the current context.
- The name 'await' does not exist in the current context.
- The name 'Context' does not exist in the current context.
- The namespace "ASP" already contains a definition for '_Page_Default_cshtml'
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.