I’m trying to clone a row x times (x = lenght of a list) however when i try to change the text of the new label according the creation of the new row, just the last one has changed. Could you please help me?
https://paste.pics/3f4d773e1dbfc0fea9e02a308b711b74
Hey there
I am not sure what you are trying to do there:
At this point, you have created a clone of the Produto_Numero_1 row which I assume contains a label, is this correct? If so, the issue could be that you are targeting ALL labels in Column 25 which includes ALL clones therefore, all labels of all previously created clones will get the same value. Am I getting the issue correctly?
Thanks
Hey K. Looks like you have a point but Nayron needs to clone a row which contains a label, you are cloning a label so… Humm…
What is “Produto_Nomero_1” ???
He starts his problem description with “I’m trying to clone a row x times” so I assume it is a row. :-S
I am extremely sorry, @nayroncbruschilw7mm1!
I gave the solution for cloning a label in a column N times
I didn’t read the starting part of your question, just jumped onto
Sorry,
Kartik
P.S., I have deleted my solution, Thanks @Deluxe for pointing!
Very welcome! I was just thinking… wouldn’t using ‘all label in clone’ in that last line sort things out? To be honest, I a bit confused as to what he is trying to achieve. Here is how I deal with cloning i.e. a Column which might contain multiple elements of the same type such as 2 buttons and 2 labels which I might want to be different so using the “all buttons” or “all labels” approach does not help.
- I set up a container such as a column in which I will create my prototype I want to clone down the road. Let’s call that container, Container A
- I create my prototype, let’s say, another column with blue background that contains 2 buttons and 2 labels. Let’s call that prototype, Container B
- I hide Container A without hiding Container B. This is actually where bending the rules takes place: Reading the Thunkable documentation it states that you cannot clone a hidden element… but what I am going to clone is not the hidden element (Container A) but instead my prototype (Container B) which resides within the hidden element (Container A). This way I can use my prototype off screen to assign it values and then clone it. This is also how I have complete control on the contents of same-kind elements, 2 buttons and 2 labels in this example.
- In my code if first assign values to my prototype and then clone it, using a loops if desired.
Just to be clear, this way the “then” part of the “Clone” block is empty as nothing needs to be done to the clone since everything has been done before creating the clone on the prototype.
Make sense?
I think, what he wants to do, when he creates a clone of a row, then he wants to clone a label inside the newly cloned row.
Just like we first clone a column & inside it, an image & then image’s caption label inside the same column.
Therefore, the column contains only an image and a label.
He want’s to clone a row, create a label in it and modify it’s text.
That’s all what I understood
Hello!
https://paste.pics/c811fbf97d16e94e891d5a8b2867e565 (printscreen of design)
Where is written “Macarrão de abobrinha com molho de tomate natural. Val.En: 340kcal” is the label i want to change in the coned row. It is in a firebase database that’s why i trim spaces of both sizes and get the #2 element of a list.
The next row cloned will receive the next product, is all referent in a product tag saved in database (“like KJH0009 for exemple”).
Produto_Numero_1 is the row inside a collum 25 that i want to clone, and change the label, button text and image, (all data of it is registered in Firebase DB).