public void DeleteContentObject(int id)
 {
     using (vwarEntities entitiles = new vwarEntities(_ConnectionString))
     {
         var contentObejct = (from co in entitiles.ContentObject
                              where co.Id == id
                              select co).First();
         entitiles.DeleteObject(contentObejct);
         entitiles.SaveChanges(true);
     }
 }
Example #2
0
 public void DeleteContentObject(int id)
 {
     using (vwarEntities entitiles = new vwarEntities(_ConnectionString))
     {
         var contentObejct = (from co in entitiles.ContentObject
                              where co.Id == id
                              select co).First();
         entitiles.DeleteObject(contentObejct);
         entitiles.SaveChanges(true);
     }
 }