DuplicateKeyException Constructor (Object, String)

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Initializes a new instance of the DuplicateKeyException class by referencing the duplicate key and providing an error message.

Namespace:   System.Data.Linq
Assembly:  System.Data.Linq (in System.Data.Linq.dll)

public DuplicateKeyException(
	object duplicate,
	string message
)

Parameters

duplicate
Type: System.Object

The duplicate key that caused the exception to be thrown.

message
Type: System.String

The message to appear when the exception is thrown.

.NET Framework
Available since 3.5
Windows Phone Silverlight
Available since 7.1
Return to top
Show: