Mark, >> i.e. make sure the datagrid is only creating rows on demand, rather than >> up front, and then requesting images and updating them when they arrive
How do you do that? What property do I set, or method is used to only load the displayed rows? Tom's code snippet is a WONDERFUL start and I get the concept, but there are a bunch of missing parts that I'm not sure how (or where) to code. Also, I don't know if it really matters or not, but Tom sent the code from his dg column, I am using a form DG. -Dan On 2/22/22, 12:51 AM, "use-livecode on behalf of Mark Waddingham via use-livecode" <use-livecode-boun...@lists.runrev.com on behalf of use-livecode@lists.runrev.com> wrote: On 2022-02-21 23:47, Tom Glod via use-livecode wrote: > This is how i did it ..... I hope this helps. > > First to use the "numberofrecords" way of setting the datagrid data. > This is key, that way you only ever trigger loading of visible rows. So I've not got much to add to Tom's method i.e. make sure the datagrid is only creating rows on demand, rather than up front, and then requesting images and updating them when they arrive Beyond a suggestion to ensure the images which are being downloaded are already suitably sized/thumbnailed for display. Decompressing images is a relatively expensive operation - decompressing and then downsizing them (thumbnailing) even more so. So, if you control the webservice that is providing the images it would probably be worth making it so that the server can send you images at the size needed and do the thumbnailing on the server (caching the results alongside the original image on the server). For maximum fidelity you want the width/height * the device pixel scale (which can vary from 1 to 3 these days). Warmest Regards, Mark. -- Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/ LiveCode: Everyone can create apps _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode