@Ap_Seh - it seems that you have been struggling with this one, so I’ve put together a simple concept app (which is copyable) to help give you a bit of a kick start
How it works:
In the Users table, there are two key columns…
Next Word ID: the ID of the next word that user will be shown
Word Last Seen: the date/time that user was last shown a word
There are also several computed columns in the Users table. Here is a quick description of each:
ite-next-word-id: this deals with an initial empty state of the Next Word ID column (if empty, then 1)
mth-next-word-id: this uses a math formula to ensure the next Word ID is an integer between 1 and 5
mth-next-word-at: this calculates the time that the next word should be shown to that user
hrs-till-next-word: this calculates the number of whole hours until the next word should be shown
mins-till-next-word: this calculates the number of minutes (minus hours) till the next word should be shown
hr/hrs & min/mins: these are used to deal correctly with the pluralisation of hours and minutes
tp-time-to-next-word: template column used to create the content to display in a hint component, showing how long till the next word is shown
ite-show-word: this contains the logic that decides whether or not to display the next word.
The words are displayed using an inline list, filtered by the Next Word ID
You’ll also see that most components have visibility conditions, using the state of the ite-show-word column
The “Got It” button does two things:
Increments the Next Word ID column for the user by 1
Sets the Word Last Seen column to the current date/time
Once the user clicks on the “Got It” button, both the word and the button will be hidden, and replaced with a hint component that shows how long until the next word is shown
The “reset” button is there so that you can simulate the next word in the list being shown
You can never make a lookup column point to a relation, though You can make a relation point to a lookup column. A lookup is the product of a relation, not the other way round. Hence you make a lookup column “relate back to” a relation and a relation “point to” a column.
Jeff always chooses his words very carefully
And his choice of words had nothing to do with my decision to build the app. I just did it for the practice
I’m not sure I understand what you are saying. A relation is not a lookup of a single column. Yes it uses a single column in one sheet to link to a single column in another sheet, but it’s still a link to an entire row. The only way to pull out a single column value from a relation is to use a lookup column that references that relation.
That’s the point I was trying to make to @Ap_Seh is that they have a relation column but I believe they were calling it a lookup when it isn’t a lookup and doesn’t function like a lookup. You can’t set a value in a component from a relation, because a relation is not a single value…it’s a row or multiple rows. If they add a Lookup column and point it to the relation column, then they can pull the word of the day out of that relation and set the component value to that lookup value.
Looking at the screenshots I did not see a lookup column, so I can only assume that there isn’t one. Yes, the my wording is a little vague, but I like to make people think a little bit and ask follow up questions if they still don’t understand something. Just telling someone to add a Lookup column may not heIp them fully understand why they need to do it. If they have to think about what I’m saying or asking, then it’s helps them to better understand how everything works together in the future.
@Darren, Thanks ! I have been trying to figure out your logic in the app. Lots to learn from it. I’ll take my time and revert if I am unable to understand something.
@Wiz Thanks. All I really wanted to know was that why isn’t the relation / lookup column displayed as a field / option in the data (of say inline list )where I can choose it, like other columns, to display its value.
I think since it does not provide the relation column in the data of the components, it would mean that displaying those values is not allowed. I am just not sure and so wanted to know it. I still really don’t know.
This I think is what I was really asking. I was thinking that since I am using the count value to lookup the word by relating the count value in Users to sno value in words, that it is a lookup but seems it’s a relation and so cannot be used to display it’s value.
So may I ask how I can instead use a lookup that I was trying to create and instead ended up creating a relation field?
Thanks.
P.S. I know Darren has been great in doing a whole app for me but I still would like, if possible, an answer to the above. The I would be able to create and use my lookup field and not a relation field, to display the value and complete my app immediately.
Another thing I cannot figure out is how / where you managed to set the text height of the word in the tile to be as big as it shows up. The inline list allows for me to set the text size to only 3 sizes, small , medium and large. but I am using the free version of glide. The largest value, in my case, sets the height to about half your size.
This is just a CSS trick to make the text in the Hint component a bit more presentable. It causes the line-breaks to be respected. If you remove it, you’ll see the change in the Hint component.
The title text is shown inside the tile because the “Show Title when Image is not available” option is selected. As far as I’m aware, you can’t change the style of that (except maybe with CSS).
Changing the text size only affects the Title/Details text that is shown below the tile.