Android Question Find Instance

fishwolf

Well-Known Member
Licensed User
Longtime User
If i draw the graphics interface to runtime, for example a button

and define the instance of button into a function or method.

can i find the instance of button into activity into other function or method?

Thanks
 

RandomCoder

Well-Known Member
Licensed User
Longtime User
Another option is to use the Tag to store a string or integer value to identify the view by. You can itterate through all the views to find the one you want or use Sender to take a reference to a view that has been clicked for example.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…