String
641
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.
Availability:
ActionScript 1.0; Flash Lite 2.0
Returns
String
- A string.
Example
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 found in the Strings.fla file in the ActionScript samples folder. The
following list gives typical paths to this folder:
■
Windows:
boot drive
\Program Files\Macromedia\Flash 8\Samples and
Tutorials\Samples\ActionScript
■
Macintosh:
Macintosh HD
/Applications/Macromedia Flash 8/Samples and Tutorials/
Samples/ActionScript
See also
toLowerCase (String.toLowerCase method)
valueOf (String.valueOf method)
public valueOf() : String
Returns the string.
Availability:
ActionScript 1.0; Flash Lite 2.0
Returns
String
- The value of the string.
Summary of Contents for Flash Lite 2
Page 1: ...Flash Lite 2 x ActionScript Language Reference...
Page 22: ...22 Contents...
Page 244: ...244 ActionScript language elements...
Page 760: ...760 ActionScript classes...