Convert.IsDBNull Method

May 11, 2014

Returns an indication whether the specified object is of type DBNull.

Namespace:  System
Assembly:  mscorlib (in mscorlib.dll)

public static bool IsDBNull(
	Object value
)

Parameters

value
Type: System.Object
An object.

Return Value

Type: System.Boolean
true if value is of type DBNull; otherwise, false.

The IsDBNull method tests whether the value parameter is equal to DBNull.Value. It is equivalent to the following code:


return DBNull.Value.Equals(value);


NoteNote:

DBNull.Value is used to indicate a value that is missing. It is not equivalent to null or to String.Empty.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2014 Microsoft