IsNull Function

Syntax:

IsNull(expr)

Group:

Variable Info

Description:

Return the True if expr is Null.

 

Parameter

Description

expr

A variant expression to test for Null.

 

See Also:

TypeName, VarType

 

Example:


Sub Main
  Dim X As Variant
  Debug.Print IsEmpty(X) 'True
  Debug.Print IsNull(X) 'False
  X = 1
  Debug.Print IsNull(X) 'False
  X = "1"
  Debug.Print IsNull(X) 'False
  X = Null
  Debug.Print IsNull(X) 'True
  X = X*2
  Debug.Print IsNull(X) 'True
End
Sub