TileList DataProvider : TileList « Container « Flex






TileList DataProvider

TileList DataProvider
  
<!--
Code from Flex 4 Documentation "Using Adobe Flex 4".

This user guide is licensed for use under the terms of the Creative Commons Attribution 
Non-Commercial 3.0 License. 

This License allows users to copy, distribute, and transmit the user guide for noncommercial 
purposes only so long as 
  (1) proper attribution to Adobe is given as the owner of the user guide; and 
  (2) any reuse or distribution of the user guide contains a notice that use of the user guide is governed by these terms. 
The best way to provide notice is to include the following link. 
To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/

-->



    <!-- dpcontrols/TileListDataProvider.mxml -->
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
    xmlns:s="library://ns.adobe.com/flex/spark" xmlns:mx="library://ns.adobe.com/flex/mx"
    initialize="initData();">
    <fx:Script> 
         
        import mx.controls.Button; 
        import mx.collections.*; 
        private var listArray:Array=[ 
            {label: "item0", data: 0},{label: "item1", data: 1}, 
            {label: "item2", data: 2},{label: "item3", data: 3}, 
            {label: "item4", data: 4},{label: "item5", data: 5}, 
            {label: "item6", data: 6},{label: "item7", data: 7}, 
            {label: "item8", data: 8}]; 
        [Bindable] 
        public var TileListdp:ArrayList; 
        private function initData():void { 
            TileListdp = new ArrayList(listArray); 
        } 
      
    </fx:Script>
    <mx:TileList dataProvider="{TileListdp}" itemRenderer="mx.controls.Button" />
</s:Application>

   
    
  








Related examples in the same category

1.Using a TileListUsing a TileList
2.Set data for a TileList controlSet data for a TileList control
3.Tile List Custom Effect and Default EffectTile List Custom Effect and Default Effect