Referencing a non-sender pragmatically-generated view.

Stepdragon

Member
Licensed User
Longtime User
Here's an example of the type of result I wish to achieve.

I have an activity with one button. If you click that button, it generates a checkbox and a button. Press it again, it creates another set, and so on. Now you can check those boxes, and hit the button again. Now each set that was checked will be removed.

The Idea here is, how can I reference specific views without:

A. being the sender
B. Being on the original code path that created it

I would imagine I //COULD// use tags and something along the lines of *for each item as view in activity.views*, but not only do I not know if that works in B4A, but Its also not very efficient for large configurations.

Can anyone point me in the right direction for this?



Here are some more details.

I've been playing with this a bit. I read another post wich made me think about possibly using arrays of views to do this. the thing is that I don't know if I can create a small array of a view, and then increase it as I need more views.

I've tried dimensioning the array at global and local levels, and tried reassigning it. nothing wants to work.

Really, there has to be a way to keep track of a progmatically generated view on a seperate code path... It opens so many possibilities.

I must say though, absolutely everything else in B4A is exceptionally easy to do... I like it, but this is something that will make or break a project for me. Any help is appreciated.
 
Last edited:

Stepdragon

Member
Licensed User
Longtime User
Thanks. I was still having some issues with it, but I took a really close look at the documentation, and did some trial and error, and I understand how to do it now.

Maybe once I clean up my code a bit I'll post a demo program to help illustrate it.
 
Upvote 0
Top