Flash CS3 Documentation |
|||
| Flash Lite 2.x ActionScript Language Reference > ActionScript classes > String > toUpperCase (String.toUpperCase method) | |||
public toUpperCase() : String
Returns a copy of the String object, with all lowercase characters converted to uppercase. The original value is unchanged.
String - A string.
The following example creates a string with all lowercase characters and then creates a copy of that string using toUpperCase():
var lowerCase:String = "lorem ipsum dolor";
var upperCase:String = lowerCase.toUpperCase();
trace("lowerCase: " + lowerCase); // output: lowerCase: lorem ipsum dolor
trace("upperCase: " + upperCase); // output: upperCase: LOREM IPSUM DOLOR
An example is also in the Strings.fla file in the ActionScript samples folder at www.adobe.com/go/learn_fl_samples. Download and decompress the .zip file and navigate to the folder for your version of ActionScript to access the sample.
toLowerCase (String.toLowerCase method)
Flash CS3
Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/flash/9.0/main/00005464.html