Flash Lite 2 |
|||
| Flash Lite 2.x ActionScript リファレンスガイド > ActionScript クラス > String > toLowerCase (String.toLowerCase メソッド) | |||
public toLowerCase() : String
String オブジェクトのコピーを返します。すべての大文字が小文字に変換されます。元の値は変更されません。
使用できるバージョン : ActionScript 1.0、Flash Lite 2.0
String - ストリング。
次の例では、すべての文字が大文字になっているストリングを作成した後、toLowerCase() を使用して、そのストリングの大文字をすべて小文字に変換したコピーを作成します。
var upperCase: String = "LOREM IPSUM DOLOR";
var lowerCase: String = upperCase.toLowerCase();
trace("upperCase: " + upperCase); // upperCase を出力する : LOREM IPSUM DOLOR
trace("lowerCase: " + lowerCase); // lowerCase を出力する : lorem ipsum dolor
"ActionScript" サンプルのフォルダの "Strings.fla" ファイルにも例が収められています。通常、このフォルダへのパスは次のようになります。
toUpperCase (String.toUpperCase メソッド)