LOTUSSCRIPT LANGUAGE
dim Int_1 as integer
dim String_1 as string
dim Bool_1, Bool_2
Int_1 = 0
print CBool(Int_1) 'prints FALSE
Bool_1 = CBool(Int_1)
Int_1 = 99
print CBool(Int_1) 'prints TRUE
String_1 = "True"
print CBool(String_1) 'prints TRUE
Bool_2 = CBool(String_1)
String_1 = "No Value"
print CBool(String_1) 'Generates type mismatch error (Error 13)
'String value must be "True" or "False" for
'successful conversion to type Boolean
print DataType(Bool_1) 'prints 11 (Boolean)
print DataType(Bool_2) 'prints 11 (Boolean)
See Also