Can't find ADo.net entity framework under wpf class library

Asier 41 Reputation points
2021-10-28T20:38:02.52+00:00

I have created a new proyect under my visual solution using a wpf class library and when I try to add a entity framework model, I cant fin anything related with ado.net entity framework to create diagrams. But when I create a wpf application, then I can add a ado.net entity framework framework element.

If I creadted a normal class library, I can find entity framework. What can I do?
144695-captura.jpg

Perhaps I haven't find the correct type of wpf class library, what wpf class library should I choose?
144656-captura.jpg

thanks

Developer technologies | Windows Presentation Foundation
Developer technologies | .NET | Other
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Hui Liu-MSFT 48,711 Reputation points Microsoft External Staff
    2021-10-29T07:03:17.043+00:00

    The target framework of the WPF class library is .NET Core, it seems that the ADO.NET entity data model cannot be used directly. If you want to use the ADO.NET entity data model, please make sure that the target framework of the project is the .NET Framework. You can refer to links ADO.Net Entity Data Model and Using Entity Framework.


    If the answer is the right solution, please click Accept Answer and kindly upvote it. If you have extra questions about this answer, please click Comment.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.