- Add a new entity to a
TrackableCollection(context.Entities.Add(entity)) (EntityState = New) - Without saving, delete the added entity from
TrackableCollection(context.Entities.Remove(entity)) (EntityState = Unmodified) - Save. (
context.SubmitChanges())
I still get validation errors from the data annotations associated with the entity, why?
public class Entity
{
[Required]
public string Name { get; set; }
}