I am having problems when initialize a variable setting value.
I set the variable with “initialize app variable” and set the value.
Then when i do “when screen starts” i try to use the variable and is undefined!!!
Everything was working. I already have an APP created from the same project.
But today i was going to test and there was an error, thats when i discover that the error was that the variable was undefined…and it happened without a reason!
Anyone with the same problem?
Please help me.
Hey @altsoftcode - can you share a screenshot of the blocks you are using?
Have you considered using the logic blocks to handle what happens if the value from a variable is undefined?
Thank you @domhnallohanlon for your answer.
There is not much to share. It is a normal procedure as described here: https://docs.thunkable.com/variables
I decided to create stored variables, cause it worked, but this means that i have to change everything i made until now.
I think it is a problem in thunkable. I tested in two devices and is the same problem.
As i said everything was working great until today and i am talking about months of work.
If you want you can try to set an app variable and then when screen starts alert the value.
Thank you very much.
If you just change the variable type from
stored then everything will be updated automatically. There are no other changes needed.
It might be? If you share a screenshot thought you will help us establish whether it actually is or not.