Solved

Flex DataGrid:  How can I access the data it contains in the order it is displayed

Posted on 2009-07-08
1
300 Views
Last Modified: 2012-05-07
I have a simple flex datagrid.
I have set dragEnabled = true, dragMoveEnabled=true and dropEnabled=true.
My users can now drag rows up and down to arrange them in the order they like.
I need to save the order they have selected, so I can arrange the rows in this way the next time they login.

How can I loop through the datagrid and get the data element name  (e.g. the value of data in dg column1) of each item of data being displayed, in the order that it has been arranged.
0
Comment
Question by:asim_uk
1 Comment
 

Accepted Solution

by:
asim_uk earned 0 total points
ID: 24803140
Turns out dragging the rows actually changes their order in the dataProvider, so:

for each( var row:Object in dgTeamKPI.dataProvider ) {
    kpiOrder = kpiOrder + row.KPI_ID +"," ;
}

Stores the user selected order in kpiOrder.
0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

First things first - Preparation We need all the part for this install and it's much nicer to have them all on hand when you need them so here's what's required. Download Eclipse 3.5 32 bit (I like the Classic flavour) from here. (http://www.e…
Riverbed Technology's webinar discusses networking for the cloud era with simplified SD-WAN cloud connectivity.
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question