[ANN] Free: Google-style typing filter for LiveCode

Bob Sneidar bobsneidar at iotecdigital.com
Mon Dec 29 18:39:29 EST 2014


I was having the same epiphany. I did this with a local mySQL database a little while back and it worked a peach. I had a little delay timer going so that if the user typed another character within a certain time frame the counter would reset. Once the user stopped typing for a small length of time, *then* the query would trigger.

What I didn’t do was the look and feel part. THAT I need to incorporate. Very cool.

Bob S


On Dec 24, 2014, at 13:47 , Peter Haworth <pete at lcsql.com<mailto:pete at lcsql.com>> wrote:

Thanks Hugh, very nice.

I couldn't resist trying this using an SQLite database instead of the
preloaded data.  I created a database with one table named Places with one
column named Data that holds the preloaded data, then imported the
preloaded data into it.

The script changes were pretty minimal, just open the database at startup,
then instead of the filter command:

put revDataFromQuery(,,gDBID,"SELECT Data FROM Places WHERE Data LIKE :1
ORDER BY Data","tSearch")

tSearch is the variable that holds the search string with "%" signs either
after or before/after depending on the wildcard setting.

The query takes an average of around 15 msecs vs the filter command taking
perhaps 2msecs but neither time is noticeable to a user.



Pete



More information about the use-livecode mailing list