Hi everyone, been searching for answers to my problems here lately and atleast google didnt give me a straight answer to this one. Ok so here comes me question:
i want to be able to use this function to create textfields with unique names. how do i change this so that i can read the parameter value to the new variable without having this namespace conflict?
function createTextField(textFieldName:String,inputField:String,formatType:String,contentBackgroundMovieClip:String):TextField {
var textFieldName:TextField = new TextField();
textfieldName.embedFonts = true;
textfieldName.autoSize = TextFieldAutoSize.LEFT;
textfieldName.antiAliasType = AntiAliasType.ADVANCED;
textfieldName.setTextFormat = setTextFormat(formatType);
textfieldName.selectable = false;
textfieldName.mouseEnabled = true;
textfieldName.text = inputField;
textfieldName.toUpperCase();
contentBackgroundMovieClip.addChild(textFieldName);
}