ActionScript 2.0 Language Reference |
|
|
|
| ActionScript classes > Locale (mx.lang.Locale) > setString (Locale.setString method) | |||
Sets the new string value of a given string ID and language code.
Availability: ActionScript 2.0; Flash Player 8
stringID:String - The identification (ID) number of the string to set.
languageCode:String - The language code.
stringValue:String - A string value.
The following example uses the setString() method to set the IDS_WELCOME string for both English (en) and French (fr).
import mx.lang.Locale;
Locale.setString("IDS_WELCOME", "en", "hello");
Locale.setString("IDS_WELCOME", "fr", "bonjour");
trace(Locale.loadStringEx("IDS_WELCOME", "en")); // hello
|
|
|
|