I have a Google sheets which serves as a Data source (it is for a community phone book). I have a Data Viewer object which shows the whole list (although it takes a little time for the records to appear when I scroll down the list).
When clicking an entry, I want to show details of this person (Data from the Google sheets). It takes a very long time for the Data to show.
This is both in preview and also after building the apk.
I’d appreciate guidance or help.
Can you show your blocks so someone can see what makes it too long to get you the vales?
I have a bunch of Labels which show the relevant info of the selected record (row).
The delay is probably due to making several different back to back api calls. Each time you call google sheets you send a message to the google API’s, and then wait on a response. Our blocks don’t execute without having received a response. So, you call, wait, apply label, the. Do it again. And again. And again. And again.
I would recommend storing objects of data if you can predictably use the data in this manner. Then you could make 1 call and consume a Json object vs making several individual calls for 1 piece of info.
Firebase is a great tool for this exact use case. Perhaps consider restructuring your data such that you do not need to make so many different data calls.
This will, undoubtedly, introduce huge delay.
If I were you, I would create a variable to retrieve the row information all at once. then I use in the row object to populate the labels.
OK. Thank you. I will try your suggestion.
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.