JScript  

JScript Data Types

[This is preliminary documentation and subject to change]

The following table shows the data types supported by JScript, including NGWS types, storage sizes and ranges. Additional types can be introduced into JScript either by importing an assembly that contains types, or by declaring user-defined types (classes).

JScript Type NGWS Type Storage size Range
Boolean System.Boolean N/A true or false
Number System.Double 8 bytes -1.79769313486231E308 to
-4.94065645841247E-324 for negative values; 4.94065645841247E-324 to 1.79769313486232E308 for positive values.
String
(variable-length)
System.String N/A 0 to approximately 2 billion Unicode characters. Each character is 16 bit (two bytes).
int System.Int32 4 bytes -2,147,483,648 to 2,147,483,647.
long (extended integer) System.Int64 8 bytes -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807.
float
(single-precision floating-point)
System.Single 4 bytes -3.402823E38 to -1.401298E-45 for negative values; 1.401298E-45 to 3.402823E38 for positive values.
double
(double-precision floating-point)
System.Double 8 bytes -1.79769313486231E308 to
-4.94065645841247E-324 for negative values; 4.94065645841247E-324 to 1.79769313486232E308 for positive values.
Date No direct equivalent N/A Dates are implemented using the JScript Date object. The range for which is approximately 285,616 years on either side of January 1, 1970.
Array No direct equivalent N/A Arrays of any type.
Function No direct equivalent N/A Function objects.
RegExp No direct equivalent N/A A regular expression object.
Object System.Object N/A Any Object reference.
Error No direct equivalent N/A An Error object.