jupixy
1
Hi all,
I don’t understand the handling of lists.
I created a value on my page:

I added a few items/records to that list.
Now I want to change (or delete) modify a special position in that list (item #3).
How to achieve this? If I use “…item#…”, I’m not able to remove or clear the item at position #3 . Or I want to change the value on this position.
How to do this?
Thanks,
jupxi
J805
2
Hmm
I think when using a state, you should still be able to do ‘minus item’. Does that work?
jupixy
3
okay… but I have this state (list) and want to store different “user answers”. The user steps through the application. if the user want to edit a already set answer (user navigates some steps back and switches another answer), I want to replace the item on a exact position in the list. If the user wants to choose another answer on step 3, then I want to replace the #3 item in the list with another string.
J805
4
Ok, let me see if I can give you an example. That seems complicated.
Challenge accepted!
jupixy
5
user_answers[3].value = ‘blablabla…’
user_answers[3].remove (??!)

J805
6
Yeah, let me give an example for you. I will work on it now. 
J805
7
1 Like
jupixy
8
Thanks. But no - doesn’t help.
Place a button outside the repeating group. behind the click (worklow), I want to modify the 3rd element of the list.
J805
9
So like a button that says I want to change item #3?
J805
12
jupixy
13
Okay. Hard to do this in Bubble. Seems like a workaround 
What Happens If 2 Strings in the List stores the exact same value?
J805
14
If it is a duplicate, you would have to do it a different way. Sometimes, it is more about adjusting your UI/UX, your database structure, or the way you are using data on the page than trying to make a lengthy work around. You might need to save the values into the database as one option so then each record is unique. Just one option. I am sure there are many ways to do what you are trying to do.
Hope that helps a bit.
system
Closed
15
This topic was automatically closed after 70 days. New replies are no longer allowed.