Data Model Flex



  
    
    [Bindable]
    public var results:String="";
    public function formatNow():void {
      phoneFormatter.format(phone.text);
      if(phoneFormatter.error == "Invalid value"){
         results=phoneFormatter.error+" - "+ phone.text;
      } else {
        results=phoneFormatter.format(phone.text);
        phone.text=phoneFormatter.format(phone.text);
      }
    }