I was making an To Do App where I wanted to get text of a List of label (To Do things) and I want to copy it, when another Label is clicked.
I tried several options but did not work.
This is one of the options I tried.
But I got the below Error
Can anyone help me with this?
I took the reference of the below
Refer this aia for how to set blocks for click event for each dynamically created list item.
DynamicComponents.aia (330.9 KB)
This block shows the name of list item (Title) in the Notifier with respect to the selected list item.
That error is because of label id is not set properly in any card view click block.
In any card view click block, get id returns card view id which contains “Card”. To use this id for label replace the Card from get id block.
Here use, Replace all text with segment block
Set segment to string “Card”
and replacement to blank string.
This error coming because the component that u are using to take text has not created
I have also tried this method.
When I click on the on the copy button it only gives the text of the copy button.
Did not Work,
It is still Copying the text on Copy Button which is content_copy
Replace your second label (copy) with a button.
Do you mean something like this
When I do it I get the same error.
What if I need buttons for another purpose like translate the text?
Is there no way to accomplish with the help of Labels?
Now try this: without using join block.
Try this -
For which component do u want to copy the text
I guess I had to elaborate it.
I created a new project as the old one was messed up and I made some changes.
This is the design of my App. (Not Focused on the UI/UX yet)
In the Blocks
The List procedure
And Lastly the block which I want to get text when Clicked
I guess this understands my problem.
First u need to check the the component is dynamic or not the if Id matches with that label that u want to copy the text then copy…
@dora_paz I think it will not work beacuse both component are same and u are setting sam eids to both
For testing purposes I created 5 labels dynamically
When any label clicked, it copies the text of that label and it works for me
beacuse u are creating only 1 label dynamically
and as u can see get property u can directly use get component variable but u are using get component block and get id block
You are right
works also like this