Search code examples
listglobal-variableslocal-variablesapp-inventor

App Inventor - Defining local variables using "length of list" equal to tinyDB GetTags


I am currently trying to design a booking system for my app, and i want to make it so that i should be able to store under a tag a certain list however i am having problems trying to make this tag be automatically generated as in the block of code it should automatically generate the tag to store the booking details ,however when i run the code it app it doesn't make more than 1 tag and so the tag remains the same even if the booking button is clicked multiple times and so it overwrites the previous data.

Link to code Booking page

I want to make it so a new tag for the db is produced each time the button is pressed.

Link to code Viewing Page


Solution

  • Below method maybe help you to solve your problem. I'm using TinyDB. I just show how we can add new item in the list of the same tag.

    enter image description here

    Next, what do you mean by "so a new tag for the db is produced each time the button is pressed"? Do you want random tag?