TinyDB the previous value plus the current value

And why are you going to make me so much? Thank you very much.

When screen initialise, i used label to show Either values present or not(no need for you)

When Save button clicked , I want to store values as a continuous lost so global variable used. After entering text and clicked save button, if values present already then new values will added to the list.

When calc button clicked, I checked length of the list. Since we are going to add last two entries I taken only last two digits for the sum.

Also if calc button clicked and if the global list contain more than 2 then the first value will be removed so continuously only last two input will be alive

I didn’t get your point?

I said that I am considerate

Any Error?? Try in companion mode. After saving a value just refresh and enter value again and save then cal button will become visible and cal it

It’s work but… I want the entered values to be combined with value in Label1

Or another case,Plus all the values entered in the TinyDB together.

Ok, let me remodify it. But I didn’t get your logic.

This is not a big issue

Thx , I’m sorry I can’t explain and english language problems

I want to be good like you

Here is the block for this method


It will sum all the values stored in the list…

according tho this only, i hope, i gave the blocks earlier…(Method1 click button)
Label will display all the stored value, in that i sum the values of entered value along with the last value from the stored value. Why mean, if user clicks save, the list will start to store all the in a list.

Ok try this,… The below picture will

  1. save the value
  2. Method1 will add the last value from the stored list along with entered value of the table
  3. Method 2 will sum all the stored values in the tinyDB list

Hit solution, if it solves. If not, mention your query again let me try to solve it

1 Like

It’s not working . why Label3 = 0 all over

I will try

If you store the values as shown in the picture above it will give the result in label3


It’s work…

I have used Label1 & 2 to cross check and it is no need i think

method1 , Why is it for you?