Why??? Definition 1172: Definition fl events.ComponentEvent could not be found.
I am trying to ask for input in an input textfield and the way Im doing it is using
import fl.events.ComponentEvent;
input_text.addEventListener(ComponentEvent.ENTER, readInput);
input_text.addEventListener(Event.CHANGE, changeHandler);
var clearing:Boolean=false;
function readInput(event:Event):void
{
input = input_txt.text;
trace(input);
clearing=true;
}
function changeHandler(event:Event)
{
if(clearing)
{
input_text.text="";
clearing=false;
}
}
in my code, however am getting a Definition 1172: Definition fl events.ComponentEvent could not be found.
I am only doing all of this junk instead of a simple input_text="" on a keycode=13 event listener; because when i do that it adds a blank return line "
"to the input when they hit enter and I dont want that. They told me i could do this and it would solve the blank extra return line problem (when i ask a person hit enter to submit the text) but they didnt mention that there would be this error. What do i do
