2 Replies Latest reply on Mar 13, 2009 10:44 PM by sathiyabala

    Adding Values to DataGrid

      I have 4 columns in the data grid, then i have two combobox and one textbox, so selecting the two combobox and entering value in textbox,now click a button so that the values are entered in the first three column of datagrid in first row. Now click another button so that the label of the button should be entered in the 4th column of the datagrid in the same first row. but it displays in the 4th column of datagrid in 2nd row.

      I need this problem to be solved.

      Can any one help

      Thanks In Advance..

        • 1. Re: Adding Values to DataGrid
          Gregory Lafrance Level 6
          It depends on how your dataProvider is implemented, and also how you are adding to it via the button click.

          If you were using an XMLListCollection, and on the first button click for the combobox and textinput data, adding a node with the data in sub-nodes, then you could just add another sub-node for the item in the XLC where the values entered for the combo boxes and text input equal what they are currently set to.

          This assumes the comboboxes and text input are not in the datagrid.

          If this is confusing, you could post simplified yet complete code for use to use in solving the problem.
          • 2. Re: Adding Values to DataGrid
            sathiyabala Level 1

            NOTE: run this mxml, select any value in second and third combobox and give value in textbox,click add. Now the values will be entered to datagrid. Then again click AND Button, it will be displayed in 2nd row 4th column of datagrid. I need it to be displayed in the 1st row 4th column of data grid. Then need to select multiple rows to save those in DB