Re: Datagrid sorting

2010-04-26 Thread Marcello Bertoli
On 23/apr/2010, at 21.46, Andre.Bisseret wrote: Actually, to do a multi-criteria sorting (here two criteria) one must sort firstly by the second criteria, then by the first one. So that one gets the names in alphabetical order inside each date. So a mixt of my two proposal seems to do the

Re: Datagrid sorting

2010-04-26 Thread Andre.Bisseret
Bonjour Marcello, Le 26 avr. 10 à 13:15, Marcello Bertoli a écrit : On 23/apr/2010, at 21.46, Andre.Bisseret wrote: Actually, to do a multi-criteria sorting (here two criteria) one must sort firstly by the second criteria, then by the first one. So that one gets the names in alphabetical

Re: Datagrid sorting

2010-04-26 Thread Marcello Bertoli
On 26/apr/2010, at 15.13, Andre.Bisseret wrote: A while later, trying to comment it, I discovered that it was working without any wait as well!!! I must confess that I am unable to explain why. I must add that the data grid I am using for trials has only 9 rows (3 dates with 3 names

Re: Datagrid sorting

2010-04-26 Thread Trevor DeVore
On Apr 21, 2010, at 12:10 PM, Marcello Bertoli wrote: I need to sort the lines of a datagrid with more than one criteria. For instance: The datagrid represents invoices with these columns: - invoice date - invoice number - invoice title When I click on the invoice date header I would like

Re: Datagrid sorting

2010-04-26 Thread Marcello Bertoli
On 26/apr/2010, at 18.01, Trevor DeVore wrote: on SortDataGridColumn pColumn switch pColumn case invoice date SortDataByKey invoice date, ... SortDataByKey invoice number, ... HiliteAndStoreSortByColumn pColumn break default

Re: Datagrid sorting

2010-04-23 Thread Marcello Bertoli
criteria sorting (maybe here Trevor can give us a hint) 2. We have to process the array of the datagrid, sorting with multicriteria and then populate again the datagrid with the new array. Any idea? Best regards Marcello___ use-revolution mailing list

Re: Datagrid sorting

2010-04-23 Thread Andre.Bisseret
, there are two chances: 1. The datagrid code can itself manage muti criteria sorting (maybe here Trevor can give us a hint) 2. We have to process the array of the datagrid, sorting with multicriteria and then populate again the datagrid with the new array. Any idea? Bonsoir Marcello

Re: Datagrid sorting

2010-04-22 Thread Marcello Bertoli
Hi Andre, thank you very much for your answer. I tried your code but it doesn't do the job. It is like pushing the column header of the datagrid two times (first the number one and the the date one). My data come from a sql base so I can (as Steven said) make the query do the work of the

Re: Datagrid sorting

2010-04-22 Thread Andre . Bisseret
Le 22 avr. 10 à 11:38, Marcello Bertoli a écrit : Hi Andre, thank you very much for your answer. I tried your code but it doesn't do the job. It is like pushing the column header of the datagrid two times (first the number one and the the date one). Bonjour Marcello, Sorry, I had read

Re: Datagrid sorting

2010-04-22 Thread Andre.Bisseret
Marcello, Seems this one might be working as you expected (?) -- in the script of the dataGrid: --- local hcColumn,theColumn --- on mouseDown put the dgHeaderControl of the mouseControl into hcColumn if hcColumn is not empty then put the dgColumn of the target into

Datagrid sorting

2010-04-21 Thread Marcello Bertoli
Hi all, I need to sort the lines of a datagrid with more than one criteria. For instance: The datagrid represents invoices with these columns: - invoice date - invoice number - invoice title When I click on the invoice date header I would like to sort the lines of the invoice datagrid first

Re: Datagrid sorting

2010-04-21 Thread stephen barncard
If the data is coming from a SQL database, make the query do the work of the multiple sorting before loading into a datagrid. On 21 April 2010 09:10, Marcello Bertoli mbert...@libero.it wrote: Hi all, I need to sort the lines of a datagrid with more than one criteria. For instance: The

Re: Datagrid sorting

2010-04-21 Thread Andre.Bisseret
Bonjour Marcello, Le 21 avr. 10 à 18:10, Marcello Bertoli a écrit : Hi all, I need to sort the lines of a datagrid with more than one criteria. For instance: The datagrid represents invoices with these columns: - invoice date - invoice number - invoice title When I click on the invoice

Re: DataGrid Sorting

2009-11-23 Thread Trevor DeVore
On Nov 22, 2009, at 10:24 AM, RevList wrote: In my datagrid, I load in a column from a SQLite database that is the number of seconds that a person has been logged in to a particular server. I have a function that converts the data into days, hrs, mins, seconds and populates another column in

DataGrid Sorting

2009-11-22 Thread RevList
In my datagrid, I load in a column from a SQLite database that is the number of seconds that a person has been logged in to a particular server. I have a function that converts the data into days, hrs, mins, seconds and populates another column in the datagrid at fill time. This works perfectly.