var emailVal:EmailValidator = new EmailValidator();
var valResult:* = emailVal.validate(email.text);
if(valResult.type == "invalid"){
Alert.show('invalid email');
return;
}
<s:TextInput id="email" />
reference
http://www.java2s.com/Code/Flex/Data-Model/UseEmailValidatortovalidateemailcelleditor.htm
訂閱:
發佈留言 (Atom)
沒有留言:
發佈留言