I had to add a 100ms delay for each step in creating the above structure and using the finished event, since I started getting errors not just with drawing the graph but also creating the dynamic structure.
Once in a while I still get an error ( duplicate dynamic id) buts its random, and wondering if there is another method on top of adding the delay to remedy this.
Creating the dynamic structure 10 times is taking around 15 seconds to complete successfully...
I'm searching an NGC star catalog (10k recordrs) for specific criteria. Once I get all the hits (29 as an example) I have to sort the results based another set of criteria and finally generate each unique graph for every star and show an image of the star, and then add a goto button.
As mentioned earlier and based on previous feedback I added the timer delay to make it work.
If I understand correctly, you want to draw (from your example number) 29 graphs and images at the same time?
It would make more sense to recycle a single (or perhaps 2 or 3) views. For swiping back and forth, you could use the view pager extension by @vknow360 (horizontal or vertical swipe) to load the next/previous graph/image. This would significantly reduce the demand on your device/app resources.
Are you drawing your graph grid everytime as well? It appears that the main layout is static, you could make a transparent png file and set this as the background ?