Chapter 3 DynaScript Predefined Objects


Boolean methods

The Boolean object has these methods:

toString method

Syntax

Boolean.toString( )

Description

Returns the value of the Boolean as a string.

Return

String.

Example

This example returns the value of the Boolean as a string:

<!--SCRIPT 
myBool = new Boolean(true);
document.WriteLn(myBool.toString() );
-->

valueOf method

Syntax

Boolean.valueOf( )

Description

Returns the value of the Boolean object.

Return

Boolean.

Example

This example returns the value of the Boolean object:

<!--SCRIPT 
myBool = new Boolean(true);
document.WriteLn(myBool.valueOf() );
-->

 


Copyright © 1999 Sybase, Inc. All rights reserved.