Change two variables

Hello everyone! Can you help me?
I am creating an app to know who has the key.


As you can see in the first image, I put the name on top. If I enter the name Jack, this word is saved below.
the phrase “Sei in possesso della chiave” means in English “You have the key”.
So Jack is the current person who is in possession of the key, while the phrase “Chi ha preso la chiave prima di te?” means in English “Who took the key before you?”, so Kate is the previous person of Jack who took the key.
If I click Back at the bottom right and then return to this page I find the name Jack repeated twice (see second image).

Why does this happen?
I insert my code, third image.

To understand this, the word “attuale1SUP” is Jack while the word “precedente1SUP” is Kate.
I hope I have explained myself well!!
I don’t understand where the issue is

I’m not sure if I understand but are these blocks I’ve circled supposed to be the same variables?

2 Likes

Aaaaaahhhhhhhhh!!! Now the code works!!! Thank you very much!!
Sorry, the mental fatigue ! :weary:

how do I try the app on a tablet that has android version 4.02? Through Thunkable Classic?

you should be able to just download the thunkable live app on the tablet for testing purposes

Edit: I don’t have a device with that version of android so this suggestion is an assumption

1 Like

Thank you!! I tried but the tablet is too old that it doesn’t find this application. I had to get another tablet :frowning:
One question: these variables can be stored in a database which is downloaded as a text file in the tablet, as an archive?
Every day it stores everything in a database and downloaded to the tablet with the assegned date.

Yes, you can save variables in a database.

The Local Storage component will allow you to save, and access files within a device.
localstorage

If you are wanting each user to have access to these, you could one of the cloud based databases available with Thunkable. See HERE for details on each.

2 Likes