Hello! I have been so impressed with Glide so far and I’m grateful that I can put apps together using what I already know (that being spreadsheets).
However I have run into a bit of a snag with my first app, which you can see here:
The app is pulling from a cell in a google sheet with a random formula. The random bits recalculate, per the google settings, either every minute or whenever the sheet is changed in some way. So, to trigger this recalculation I made a button on each screen of my app that inserts the current date/time into a page on the sheet.
This seems to be working but it is so slow.
Do any of you have any tips? Would transferring the sheets from google to Glide increase the refresh speed at all? Is there a better function than what I have set up?
Thanks so much.
The short answer here is to do your randomisation inside Glide. Would need to understand more about your setup to advise the best way to do that. But it might be something as simple as a Single Value → Random and/or a Reshuffle action.
There will always be a sync delay with Google Sheets, so as a general rule it’s best to avoid using any sheet formulas at all.
Thanks! Essentially I have a list of options and the formula is randomly calling one of those options into a cell. This cell is what Glide is displaying.
If I copy my sheets over to glide and the formula work, what action does the button need to be to trigger the formula?
Forget about your formula, you don’t need that.
You should be able to use a Single Value → Random column, and set your Button action to do a reshuffle, then a Set Column values, setting the value from the Single Value column into a User Specific Column.
It’s important that you write the value to a User Specific column, otherwise every time a user taps a button, the value will change for all users (which would be what is happening the way you currently have it set up).
Check out an example of generating random values here:
Glide: Daily Random Point Awards