VBScript IsEmpty関数

定義と使用法

IsEmpty関数は指定された変数が初期化されているかどうかのボルン値を返します。初期化されていない場合、trueを返し、それ以外の場合はFalseを返します。

構文

IsEmpty(expression)
パラメータ 説明
expression 必要です。表現(通常は変数名です)。

dim x
document.write(IsEmpty(x))
x=10
document.write(IsEmpty(x))
x=Empty
document.write(IsEmpty(x))
x=Null
document.write(IsEmpty(x))

それぞれ出力される:

True
False
True
False