Detecting Text Input
How do i detect if there is some text entry in the input text field.
---------------------------------------------------------------------- -------------
this.tf1_txt.text = "";
this.tf1_txt.onSetFocus = function() {
tf1_txt.text=(tf1_txt.text == "")? "" : tf1_txt.text ;
}
this.tf1_txt.onChanged=function(){
if(this.tf1_txt.text==""){
this.submit_btn.enabled=false;
}else {
this.submit_btn.enabled=true;
}
}
this.submit_btn.onRelease = function () {
gotoAndStop("complete");
}
---------------------------------------------------------------------- -----------------
If I am using If . . else if. How would the above code mentioned in red color change ?