I am new to Entity Framework...i have created a EF5 model  , how do i
persist this to a sql compact database file... i do not appear to see a
method  like db.createdatabse..is this possible?

 

Examples suggest something like 

 

using (var context = new MyDbContext()) {

  if (!context.Database.Exists()) {//not defined....

    // Create the SimpleMembership database without Entity Framework
migration schema

    ((IObjectContextAdapter)context).ObjectContext.CreateDatabase();

 

 

Anthony

  }

 

 

 

 

 

Reply via email to