This page is Ready to Use

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

toString

Summary

Returns a string representation of a string.

Syntax

string.toString()
string
Required. The object to represent as a string.

Return Value

The string representation of the string.

Examples

The following example illustrates the use of the toString method with a string.

var string = "this is a test";
 var strStr = string.toString();
 document.write(strStr);

 // Output: this is a test

Attributions

  • Microsoft Developer Network: Article