[Contents]

String

Converts the specified object to a string.

Core function

Syntax

String(obj)

Parameter

obj
An object.

Description

When the object is a Date object, String returns a string representation of the date. Its format is: Thu Aug 18 04:37:43 Pacific Daylight Time 1983.

Example

The following example converts the Date object to a readable string.

D = new Date (430054663215); 
print (String(D));
This prints "Thu Aug 18 04:37:43 Pacific Daylight Time 1983."

See also

String


[Contents]

Last Updated: 10/31/97 16:38:00


Copyright © 1997 Netscape Communications Corporation