[Gambas-user] DataView Help

Benoit Minisini benoit.minisini at gambas-basic.org
Wed Jul 12 23:54:34 CEST 2023


Le 12/07/2023 à 22:01, T Lee Davidson a écrit :
> On 7/12/23 15:14, Benoit Minisini wrote:
>> Le 12/07/2023 à 01:14, T Lee Davidson a écrit :
>>> On 7/11/23 08:40, Gianluigi wrote:
>>>> I still couldn't select the correct row though, I always end up 
>>>> selecting the last one
>>>
>>> It appears that DataView.Find assumes the sort order of the view is 
>>> by `students_id`. But, it isn't always. In fact, when the application 
>>> launches, the view is sorted by `surname` descending.
>>
>> The Find() method takes the current sort order defined in the 
>> DataSource by the DataView control.
> 
> Hmmm, I don't find any sort order property in either DataSource or 
> Dataview.
> 

As I said, you have a Sort and an Ascending property in DataSource. You 
use them to define which field is used for sorting, and i which direction.

Regards,

-- 
Benoît Minisini.



More information about the User mailing list