Set and get form state : Form State « Components « Flex

Home
Flex
1.Chart
2.Components
3.Container
4.Data Model
5.Development
6.Effects
7.Event
8.Graphics
9.Grid
10.Style
Flex » Components » Form StateScreenshots 
Set and get form state
Set and get form state
          
<?xml version="1.0"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
    <mx:states>
        <mx:State name="Register">
            <mx:SetProperty target="{loginPanel}" name="title" value="Register" />
            <mx:SetProperty target="{loginButton}" name="label" value="Register" />
        </mx:State>
    </mx:states>
    <mx:Panel id="loginPanel" title="Login" horizontalScrollPolicy="off" verticalScrollPolicy="off">
        <mx:Form id="loginForm">
            <mx:Button label="Login" id="loginButton" />
        </mx:Form>
        <mx:ControlBar width="100%">
            <mx:Button label="Change State" click="currentState =currentState=='Register' ? '':'Register';" />
        </mx:ControlBar>
    </mx:Panel>
</mx:Application>

   
    
    
    
    
    
    
    
    
    
  
Related examples in the same category
1.Switch form stateSwitch form state
2.Add Form control in stateAdd Form control in state
3.Change form control property in stateChange form control property in state
4.Highlight new added form item during state changingHighlight new added form item during state changing
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.