IT:AD:Code First:HowTo:Get Started
Summary
Process
- In Visual Studio…
- In a new Console Project…
- As per 1):
Install-Package Microsoft.AspNet.WebApi.OwinSelfHost- and create the routing.
- Test it before getting on to the db site.
Install-Package EntityFrameworkorInstall-Package EntityFramework.SqlServerCompact- Accept the licenses…
- May require a restart if it is the first time you've installed EF.
- Back in Visual Studio… * Create a SqlServer CE connection string.
<configuration>
<connectionStrings>
<add name="FooProjectDbCN"
providerName="System.Data.SqlServerCe.4.0"
connectionString="Data Source=|DataDirectory|\Data\FooProjectDb.sdf"/>
</connectionStrings>
</configuration>