vbnet IsNull

    Function IsNull(Of T)(ByVal Value As T, ByVal DefaultValue As T) As T
        'checks if a variable is Null and returns a specified default value
        If Value Is Nothing OrElse IsDBNull(Value) Then
            Return DefaultValue
        Else
            Return Value
        End If
    End Function
IsNull in VB.NET

Updated: Saturday 2nd October 2010, 20:03am

There are 0 comments

Leave a comment of your own

Comments are currently closed.