MaximumValueValidationException Constructor (String, String, Decimal, Decimal, Exception)

Initializes a new instance of the MaximumValueValidationException class with the specified error message, parameters, and the inner exception that is the cause of this exception.

Namespace:  Microsoft.CommerceServer
Assembly:  Microsoft.CommerceServer.CrossTierTypes (in Microsoft.CommerceServer.CrossTierTypes.dll)

Syntax

'Declaration
Public Sub New ( _
    message As String, _
    propertyName As String, _
    maxValue As Decimal, _
    actualValue As Decimal, _
    inner As Exception _
)
'Usage
Dim message As String
Dim propertyName As String
Dim maxValue As Decimal
Dim actualValue As Decimal
Dim inner As Exception

Dim instance As New MaximumValueValidationException(message, _
    propertyName, maxValue, actualValue, _
    inner)
public MaximumValueValidationException(
    string message,
    string propertyName,
    decimal maxValue,
    decimal actualValue,
    Exception inner
)
public:
MaximumValueValidationException(
    String^ message, 
    String^ propertyName, 
    Decimal maxValue, 
    Decimal actualValue, 
    Exception^ inner
)
public function MaximumValueValidationException(
    message : String, 
    propertyName : String, 
    maxValue : decimal, 
    actualValue : decimal, 
    inner : Exception
)

Parameters

  • message
    Type: System..::.String
    The error message that explains the reason for the exception.
  • propertyName
    Type: System..::.String
    Name of the property that violated the range constraint.
  • maxValue
    Type: System..::.Decimal
    Maximum value allowed for this property. If no maximum is enforced, this value is the maximum value allowed for the decimal type.
  • inner
    Type: System..::.Exception
    The exception that is the cause of the current exception, or a nullNothingnullptra null reference (Nothing in Visual Basic) reference (Nothing in Visual Basic) if no inner exception is specified.

Remarks

If the inner parameter is not a nullNothingnullptra null reference (Nothing in Visual Basic) reference, the current exception is raised in a catch block that handles the inner exception.

MaximumValueValidationException is thrown when an attempt is made to save an entity and at least one numeric property of that entity exceeds the maximum allowed value.

Permissions

See Also

Reference

MaximumValueValidationException Class

MaximumValueValidationException Members

MaximumValueValidationException Overload

Microsoft.CommerceServer Namespace