Use multiple : ModuleLoader « Development « Flex






Use multiple

Use multiple <mx:AddChild>
            

<?xml version="1.0"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
  <mx:states>
    <mx:State name="NewVBox">
      <mx:AddChild relativeTo="{v1}">
        <mx:VBox id="v2" />
      </mx:AddChild>
      <mx:AddChild relativeTo="{v2}">
        <mx:Button id="buttonNew1" label="New Button" />
      </mx:AddChild>
      <mx:AddChild relativeTo="{v2}">
        <mx:Button id="buttonNew2" label="New Button" />
      </mx:AddChild>
      <mx:AddChild relativeTo="{v2}">
        <mx:Button id="buttonNew3" label="New Button" />
      </mx:AddChild>
    </mx:State>
  </mx:states>
  <mx:VBox id="v1">
    <mx:Button label="Change State" click="currentState = currentState=='NewVBox' ? '':'NewVBox';" />
  </mx:VBox>
</mx:Application>

   
    
    
    
    
    
    
    
    
    
    
    
  








Related examples in the same category

1.Load and unload a module by using the Button controlsLoad and unload a module by using the Button controls
2.Load module using MXML
3.Unloading a module using ActionScript
4.Preload modulePreload module
5.Using the ModuleLoader class to load modules
6.Build a unique query string for the module loadingBuild a unique query string for the module loading
7.Report the level of completion during the module's loading processReport the level of completion during the module's loading process
8.Loads and unloads the module when you click the buttonLoads and unloads the module when you click the button
9.Add event listener for loading a Module with ActionScriptAdd event listener for loading a Module with ActionScript
10.Add event listener for module loading progress with ActionScriptAdd event listener for module loading progress with ActionScript
11.Add event listener when module loading is ready with ActionScriptAdd event listener when module loading is ready with ActionScript
12.Add event listener for unloading a module with ActionScriptAdd event listener for unloading a module with ActionScript
13.Module load, progress, ready, setup and unload eventsModule load, progress, ready, setup and unload events