| toUpperCase() The toUpperCase() method is used to convert all of the string charaters specified to upper case characters, regardless of where they came from or what their original capitalization was. This method is used with a String object. syntax: stringName.toUpperCase EXAMPLE var upperString = new String("This is the string text."); document.write(upperString.toUpperCase() ); The example shows a new String being created which contains the text "This is the string text.". The document.write statement is then used to write the text to the screen utilizing the toUpperCase() method to tell the browser to display the text in all uppercase letters, as shown in the following ouput: THIS IS THE STRING TEXT. |