Reference data from ArrayCollection from DataGridColumn : DataGridColumn « Grid « 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 » Grid » DataGridColumnScreenshots 
Reference data from ArrayCollection from DataGridColumn
Reference data from ArrayCollection from DataGridColumn
        
<?xml version="1.0"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
    <mx:DataGrid width="500">
        <mx:columns>
            <mx:DataGridColumn headerText="City" dataField="city" />
            <mx:DataGridColumn headerText="Population (within city limits)" dataField="population" />
        </mx:columns>
        <mx:ArrayCollection>
            <mx:Array>
                <mx:Object city="A" state="CA" population="3" />
                <mx:Object city="B" state="NY" population="8" />
                <mx:Object city="C" state="IL" population="2" />
                <mx:Object city="D" state="PA" population="1" />
            </mx:Array>
        </mx:ArrayCollection>
    </mx:DataGrid>
</mx:Application>

   
    
    
    
    
    
    
    
  
Related examples in the same category
1.Link Object attribute with DataGridColumnLink Object attribute with DataGridColumn
2.Set DataGridColumn to not editableSet DataGridColumn to not editable
3.Set header text for DataGridColumnSet header text for DataGridColumn
4.Toggle the visibility for a DataGridColumnToggle the visibility for a DataGridColumn
5.Hide DataGridColumn by setting visible to falseHide DataGridColumn by setting visible to false
6.Using DataGridColumn to control column titlesUsing DataGridColumn to control column titles
7.Using a label function to support a multicolumn DataGridUsing a label function to support a multicolumn DataGrid
8.DataGrid column with an inline item rendererDataGrid column with an inline item renderer
9.Set Column width for DataGridSet Column width for DataGrid
10.Set an Array element to the child tag of the tagSet an Array element to the <mx:columns> child tag of the <mx:DataGrid> tag
11.Hiding and displaying DataGrid columnsHiding and displaying DataGrid columns
12.Sorting a DataGrid on multiple columnsSorting a DataGrid on multiple columns
13.Resizable DataGridColumnResizable DataGridColumn
14.DataGridColumn Header TextDataGridColumn Header Text
15.DataGridColumn editorDataFieldDataGridColumn editorDataField
16.DataGrid with DataGridColumnDataGrid with DataGridColumn
17.DataGrid and DataGridColumnDataGrid and DataGridColumn
18.Use to set optionsUse <mx:DataGridColumn> to set options
19.DataGrid Default Columns
20.DataGrid Explicit Columns
21.Use Labels from ArrayCollection as the column title for DataGridUse Labels from ArrayCollection as the column title for DataGrid
22.Specify Sort Functions for DataGrid Columns
23.Specify an Array element to the child tag of the tagSpecify an Array element to the <mx:columns> child tag of the <mx:DataGrid> tag
24.DataGrid Visible ColumnDataGrid Visible Column
25.Handling a user interaction and passing only data to a function
26.Item renderer that renders an image in a column
27.Use item editorsUse item editors
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.