Is this feature is possible ?
Hi,
I use the sort feature on columns.
I would like to sort also by row on same grid, ie when I click on a row the
columns arrange in the order of cells values of clicked row.
Is it possible ?
Thanks.
JL2008
August 6,
Alex (ActiveWidgets)
August 6,
Hi Alex,
Thanks for this idea, but is there an other method that not hide columns, a swap fonction for two columns ?
Thanks.
JL2008
August 8,
Hi,
setColumnIndices can show all columns in a different order without hiding any columns.
The example on the page that Alex mentioned (
http://www.activewidgets.com/aw.ui.grid/column-indices.html ) shows columns 2 and 0 and hides column 1.
If you use something like obj.setColumnIndices([2,0,1]) it will show column 2, then column 0 and then column 1
So, I think it can be used to sort the columns.
Ankur
Ankur Motreja
August 8,
Hi Ankur,
Yes, it's okay for me.
But my problem is to re-order a row in fonction of the values of cells in this row, then that re-order also the columns ...
I don't want to hide columns ...
My table :
headers | col 1 | col 2 | col 3 | col 4 |
row 1 | aa | bb | cc | |
row 2 | dd | ee | | ff |
row 3 | | gg | hh | |
If I click on row 3, my table would be :
headers | col 2 | col 3 | col 1 | col 4 |
row 1 | bb | cc | aa | |
row 2 | ee | | dd | ff |
row 3 | gg | hh | | |
Because I have re-order my row 3 with values of row 3.
Then the cols have been re-ordered.
Thanks.
JL2008
August 11,
Hi,
I have coded a solution that runs with setColumnIndices(), but I think a swap function between two columns will be an useful feature.
Thanks everybody for your help.
JL2008
August 11,