Introduced
Demonstrates the application of validation controls in Flex 3.0, and the application of various easing effects (easing)
Validator-the base class for various validation controls, which can be used for required validation
Datevalidator-Date validation control
Emailvalidator-email validation Controls
Regexpvalidator-Regular Expression validation control
Easing (easing)-the system's own animation easing effect, and custom easing effects
Encryption/decryption-application of AS3 library for common encryption algorithms
Other-some other common things
Online Demo
Http://www.cnblogs.com/webabcd/archive/2009/11/09/1598980.html
1, Validator.mxml
<?xml version= "1.0" encoding= "Utf-8"?>
<!--
a Demo of the base class Validator of various validation controls, which can be used for mandatory validation
-->
<mx:panel xmlns:mx= "Http://www.adobe.com/2006/mxml"
layout= "Absolute" width= "height=" "title="
Validator-validator (Other validator base class, available for required inspection
) ">
<mx:validator id=" Validator "
source=" {txtinput} " property= "text"
required= "true" requiredfielderror= "Please enter the required field"
trigger= "{btnsubmit}" triggerevent= "click "
/>
<mx:Form>
<mx:formitem label=" required fields: ">
<mx:textinput id=" Txtinput "/ >
</mx:FormItem>
<mx:formitem >
<mx:button id= "btnsubmit" label= "Validation"/>
</mx:FormItem>
</mx:Form>
</mx:Panel>