You need to install EntityFramework.dll (EF API) in your project in Visual Studio in order to work with the Code-First approach.
Here, we will install Entity Framework API (EntityFramework.dll) via NuGet in Visual Studio. (You can install EF via NuGet the same way in any version of Visual Studio.)
Right click on your project in the solution explorer and select Manage NuGet Packages...
This will open the Manage NuGet Packages dialogue box. Search for EntityFramework in the top left search box and press Enter. It will display all the API/plug-ins starting with EntityFramework as shown below.
Select EntityFramework (make sure that the author is Microsoft and the version is 6.x) and click on Install. This will open the preview box as shown below. Review the changes and click OK.
Again, click on the I Accept button in the License Acceptance dialogue box to start the installation.
This will install Entity Framework API in the project.
After installation, make sure that the appropriate version of EntityFramework.dll is included in the project.
Now, we are ready to use Entity Framework in our project. Let's create our first simple code-first example in the next chapter.