I'm at work now.. okee here goess..
-copy the native file called "locale.as" from your macromedia install file..
you will find it in the sub folder "mx"
-next to your fla/swf make a folder called "mx" and copy the "locale.as" in it
-to make sure that your fla grabs your own native file instead of the one in
the install folder you need to go to the publish window.. go to the tab "flash"
and next to the pull down for the actionscript version you are using you ahve
the button "settings" ... push that... then push the "+" button in that window
and a 2 things... one is "." and the other is "$(LocalData)/Classes" (the dot
should be the upper one in the sceme).
-Now your "locale.as" will be found before the original "locale.as" ..
-Because the Stringmap is a private object.. only visible for the locale
class... you need to go into "locale.as".. and in the variable defination at
the top change
privat static var stringMap:Object = new Object();
to
public static var stringMap:Object = new Object();
-Now you can direct to the stringmap... when de xml is parsed to the
stringmap.. it will attach variables.. with the name the same as the string
id's.. and the value the same as the textvalue...
-now you can ask a stringvalue by doing the fallowing....
stringMap = mx.lang.Locale.stringMap;
nameValue = "ID_TEST";
textValue = stringMap[nameValue]
mytextfield_txt.text = textValue ;
That's all there is to it...
Hope this helps.. been searching for answers to these questions for a long
time.. but just found them.. so funny that someone else needs it aswell:)
Best Regards,
Dennis
I Sioux,
www.isioux.nl