Flex DataGrid with ComboBox itemRenderer

后端 未结 3 838
轻奢々
轻奢々 2021-02-04 14:12

I\'m going spare trying to figure out the \"correct\" way to embed a ComboBox inside a Flex (3.4) DataGrid. By Rights (e.g. according to this page http://blog.flexmonkeypatches.

3条回答
  •  星月不相逢
    2021-02-04 14:41

    The easiest way to add itemRenderers to DataGrids is to make a custom MXML component. In your case make a canvas, HBox, or VBox as the custom component and add the combobox as a child.Set the dataProvider on the dataGrid itself and assign the itemRenderer to the column, and then override the set data function of the itemRenderer to access all data from the given data provider for that instance as seen below:

    
    
        
       
    
    
     
    

    This method will be called for each instance of the itemRenderer

提交回复
热议问题