The following example shows you how you can validate email addresses in a Flex application using the EmailValidator class and the validate() and static EmailValidator.validateEmail() methods.
Full code after the jump.
Continue reading ‘Validating email addresses using the EmailValidator class in Flex’
The following example shows you how to use the StringUtil.trim() method in Flex to remove leading and trailing whitespace from form fields before validating user input. This allows you to make sure that user’s don’t try anything sneaky like enter spaces instead of characters to bypass any minimum length validation you may have in place when validating data.
Full code after the jump.
Continue reading ‘Trimming strings using the Flex StringUtil class’s trim() method’