there is no ado.net entity data model in visual studio [duplicate]

我的未来我决定 提交于 2019-11-30 00:20:11

问题


After installed Visual Studio 2013 and create a new MVC4 internet application project : Visual Studio Doesn't have Ado.net Entity Data Model when i click on add->new item-> Why? I reinstall it but ther is no change ...


回答1:


Here's an updated solution I found as I had the same problem with Visual Studio 2015: ado.net model for db is gone Visual studio 2015

Paraphrasing: Change your installation of Visual Studio 2015 and include the Microsoft SQL Server Data Tools (via Control Panel > Program & Features > VS2015 > Change > Modify > Windows and Web Development > Microsoft SQL Server Data Tools).

After downloading the extension and restarting Visual Studio, you should be able to add ADO.NET Entity Data Model as a new item.

As I learned the hard way trying to follow older Visual Studio tutorials, trying to use View > Other Windows > Data Sources etc. doesn't do the same thing.




回答2:


You have to install a the Entity Framework NuGet Package by right-clicking the specific project and then select "Manage NuGet Package". It'll pop-up a Window where you can search for existing packages online and install them




回答3:


you should try to run VS as administrator. I've tried both ways, first, the common way that is to run VS with left click, doing it like this I have the same problem: no ADO.NET Entity Data Model option. However, if I run it as administrator (right click -> run as administrator) everything shows up.




回答4:


I'm not able to reproduce your issue.

I created a new project using the Web > Visual Studio 2012 > ASP.NET MVC 4 Web Application template and choosing Internet Application from the next dialog. I then selected Add > New Item... from the project context menu and clicked on Data node in the tree view on the left. The first item in the list was ADO.NET Entity Data Model:

You can find the required template even quicker by searching for it:

Also, if you don't have a specific reason for using the template you mentioned when creating a new MVC application I would suggest you stick with the new universal ASP.NET Web Application template instead.



来源:https://stackoverflow.com/questions/21073975/there-is-no-ado-net-entity-data-model-in-visual-studio

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!