I added a specific item in the name3 list to 1re.
I want to delete the entry that went into 1re from name3.
What should I do?
The attached picture does not work as I want.
Your problem is a fundamental flaw in the logic.
Once you figure how to do it, then it will be up to you to decide how else you want to deal with it and address it.
The flaw is as follows:
Suppose you have your name3 list = { A, B, C}
Then you go in the loop with item βjβ being first βAβ.
Note that βjβ is not β1β (the number index of βAβ in your name3 list) but the VALUE βAβ.
Now, assuming that βAβ is indeed a number of seconds since 1970, and that you add βAβ at the end of the β1reβ list, you are now proceeding to remove this βAβ from name3, and that is where this gets double faulty.
If βAβ is NOT an index, and is indeed the number of seconds since 1970 of some recent event, you are trying to remove item #1,550,000,000 in a list. I am pretty sure you do not have a thousand million entries into that list, as it would likely exceed the memory of your device already.
On the other hand, if βAβ is an index and happen to be set to β1β for the first iteration of the loop, you would be removing βAβ from the original { A, B, C} list, and therefore name3 would then be {B, C}.
On the second iteration of the loop, the one that wants to process (and remove) βBβ, you would be looking at removing the second entry from what is the updated name3, and that happens to be βCβ (i.e. NOT βBβ).
What you should do is take a few steps back and work out the detail of what the list should be with (say) 3 or 4 entries, on paper, keeping track of what would happen to the content of β1reβ and βname3β as you go through a few iterations of the loop. Then revise your logic accordingly.
Isnβt it logical to do it like a picture?
This is not what I want.
So how do I get the results I want?
Are the items in var app Name3 all numbers? Are you trying to exclude any entry from before 1970?
name3 is a number in seconds. I want to save the time before the current time to 1re and remove it from name3.
1re stores the value I want well.
It should not be deleted from name3.
You donβt want to remove #j, you want to remove item j. You want to first find the item you donβt want and figure out its index (position in the list). Then you can remove it once you know which # it is in the list. Is it first, second, third, etc.
check this out.
these blocks do what you want.
you can play with my example here
https://x.thunkable.com/copy/122ff1edd2080e7973f492f2ededc480
Aha!
When I try to remove it, is it an index removal?
Iβm not trying to remove the index number.
I want to remove j items.
For example, 1528000 is the time.
I want to delete this 1528000 time.
I donβt know the index number of this.
Is there a way to delete by item name time?
Thank you.
Succeeded.
But in my complicated app, it still doesnβt work as I want.
Anyway, the basics made sense.
@mom7667yafy - were you able to get this app working the way you wanted it to?