Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2017-02

Does anybody know a TStrinGrid-Component capable of sorting Date. Time, Float ...

3 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

John Landmesser

Hi,

i searched some time for such a component ... in vain!

So i developed myself a TStringGrid, that sorts columns with TDate, TTime, TFloat ...

I can't believe that this doesn't allready exists for Lazarus?!

For example i found http://www.tkweb.eu/en/delphicomp/kgrid.html BUT!! "Written as TCustomControl descendant, this is not a TCustomGrid enhancement"
So, no LoadFromCSV etc ... very bad!

Some sort of TSortGrid from Delphi-Zip would be nice.

Tipps are welcome!

Reply by email

Martin Schreiber
to John Landmesser
John Landmesser wrote 7 lines
Hi, i searched some time for such a component ... in vain! So i developed myself a TStringGrid, that sorts columns with TDate, TTime, TFloat ...

TWidgetGrid from MSEgui supports it. There TDataEdit descendendants (TStringEdit, TRealEdit, TDateEdit...) can be placed in the grid and build a column of the given type. TwidgetGrid does not inherit from TStringGrid but from TCustomGrid. There is also TDBWidgetGrid which connects to a TDatasource.

The code is here:
https://gitlab.com/mseide-msegui/mseide-msegui

I can't believe that this doesn't allready exists for Lazarus?!

The implementation is very complex...

Martin

Reply by email

Werner Pamler
to John Landmesser: i searched some time for such a component ... in vain! So i developed myself a…
John Landmesser wrote 19 lines
Hi, i searched some time for such a component ... in vain! So i developed myself a TStringGrid, that sorts columns with TDate, TTime, TFloat ... I can't believe that this doesn't allready exists for Lazarus?! For example i found http://www.tkweb.eu/en/delphicomp/kgrid.html BUT!! "Written as TCustomControl descendant, this is not a TCustomGrid enhancement" So, no LoadFromCSV etc ... very bad! Some sort of TSortGrid from Delphi-Zip would be nice. Tipps are welcome!

Try the TsWorksheetGrid from the fpspreadsheet package (http://wiki.lazarus.freepascal.org/TsWorksheetGrid). It derives from TCustomGrid, but be warned of some different behavior from the StringGrid here and there.

Reply by email