I have successfully converted a VCL project using Mida Converter to FMX. It uses MyBase local database binary *.cds files and loads them into the grid. In VCL the largest file only takes about 3 seconds (the Canada file which has 309,000 records), but in the FMX version using livebindings it takes about 220 seconds. Is there any way to speed up the process? I'm not using LoadFromFile(), but do this in code:
Hi,
Pieter Scheldeman2015-02-06 13:01:22
Thanks Pieter, that fixed it. Running fast now (no more than 4 seconds on the largest file).
The TMSFMXLiveGrid doesn't seem to know how to focus the result in a locate request on the ClientDataSet. In the VCL version the code is like this:
To be more precise, it does select the first result, but the scrollbar is set all the way to the top. In a list of typically 30,000 records this is not ideal. Is there a way to set the scrollbar position in the grid to highlight the result in the middle of the viewscreen?
When I press the search button successive times I get different results. The first time it sets up the list in alphabetical descending order, next it does it in ascending order, then it does the locate and it cycles like this each time I click the search button. So I set the Sorting.Mode to gsmNone, but no luck - still the same cycle.
Hi,
OK. Where do I send it?
Right now the locate is working, but the sort.mode := gsmNormal is not. I have 2 grids using sort in the project and one works and the other doesn't and I'm not sure why. Tried to make sure that both use identical options.
Hi,
TObject; ACol: Integer;
Boolean);
The strange thing though is that it did work at first and now it doesn't. The live bindings were there from the beginning from the Mida converter. I changed some properties but I didn't write any code to sort manually yet.
I think I found the problem, one is using TFMXLiveGrid (doesn't work) and the other is using TFMXGrid (does work). Do you have an example of an OnCustomCompare so I can do a sort on a column alphabetically or numer? I see the TSortFormat for each column.
Hi,
OK. Thanks!