02-01-2013 09:01 AM
Hi all,
I want to add the one container in another container more than one time and the no of times will be changed according to requirement. I am trying to add the container using JavaScript but it is not working. I want to do this in qml not in cpp.
Please provide suggestion for this.
Thanks in advance.
Solved! Go to Solution.
02-01-2013 09:20 AM
You can use ComponentDefinition to declare the component which you want to clone:
https://developer.blackberry.com/cascades/document
Then create it using .createObject and .add to first container multiple times in a for loop.
Another way is creating a ListView and manipulating it's dataModel to create a required number of items.
02-01-2013 09:48 AM
Thanks Zmey,
It is working for me thanks for your suggestion. ![]()