Share via


DbEntityValidationException Class

Definition

Exception thrown from SaveChanges() when validating entities fails.

[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1032:ImplementStandardExceptionConstructors", Justification="SerializeObjectState used instead")]
[System.Serializable]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1709:IdentifiersShouldBeCasedCorrectly", Justification="FxCop rule is wrong; Database is not two words.", MessageId="Db")]
public class DbEntityValidationException : System.Data.DataException
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1032:ImplementStandardExceptionConstructors", Justification="SerializeObjectState used instead")]
[System.Serializable]
public class DbEntityValidationException : System.Data.DataException
type DbEntityValidationException = class
    inherit DataException
Public Class DbEntityValidationException
Inherits DataException
Inheritance
DbEntityValidationException
Attributes

Constructors

DbEntityValidationException()

Initializes a new instance of DbEntityValidationException.

DbEntityValidationException(String, Exception)

Initializes a new instance of DbEntityValidationException.

DbEntityValidationException(String, IEnumerable<DbEntityValidationResult>, Exception)

Initializes a new instance of DbEntityValidationException.

DbEntityValidationException(String, IEnumerable<DbEntityValidationResult>)

Initializes a new instance of DbEntityValidationException.

DbEntityValidationException(String)

Initializes a new instance of DbEntityValidationException.

Properties

EntityValidationErrors

Validation results.

Applies to