Sqlite and performances in LiveCode

Trevor DeVore lists at mangomultimedia.com
Wed Mar 14 10:05:12 EDT 2012


On Tue, Mar 13, 2012 at 5:46 PM, Pete <pete at mollysrevenge.com> wrote:

> OK, found the problem.  I had a set dgProps["sort by column"] statement
> after setting the dgNUmberOfRecords.  Moved that to a place where
> dgNumberOfRecords is zero and only one cycle of GetDataForLine happens now.
>

Great. Just remember that anytime a redrawing of the data grid has to occur
(e.g. when changing sorting) GetDataForLine has to be called.


> Thanks for the help in tracking it down.  There are a lot of nuances
> to using dgNumberOfRecords!


Yes there are. GetDataForLine is a (bolted on) means of providing an
approach that separates the control from the data so the data doesn't
reside within the view control itself. The API for the data grid was built
around the standard LiveCode control behavior where the data resides within
the control.

There really is room for a data grid-like control that is really just a
view and does nothing more than display data that is fed to it from a data
source.

Regards,

-- 
Trevor DeVore
Blue Mango Learning Systems
www.clarify-it.com    -    www.screensteps.com



More information about the use-livecode mailing list