Latest web development tutorials

VBScript IsNull Function

VBScript Reference Complete VBScript Reference

IsNull function returns a Boolean value indicating whether an expression specified contains invalid data (Null). If the expression is Null returns True, otherwise False.

grammar

IsNull(expression)

参数 描述
expression 必需。一个表达式。

Examples

Examples

<script type="text/vbscript">

Dim x
document.write(IsNull(x) & "<br />")
x=10
document.write(IsNull(x) & "<br />")
x=Empty
document.write(IsNull(x) & "<br />")
x=Null
document.write(IsNull(x))

</script>

Examples of the above output:

False
False
False
True

try it"

VBScript Reference Complete VBScript Reference